Skip to content

Commit 665246a

Browse files
committed
Legge til logllevel som input
1 parent 7a8d799 commit 665246a

File tree

2 files changed

+25
-3
lines changed

2 files changed

+25
-3
lines changed

.github/workflows/release.yml

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ on:
77
description: "Optional: Specify a release tag to use instead of the latest"
88
default: ""
99
required: false
10+
loglevel:
11+
type: string
12+
description: "Optional: Specify the log level"
13+
required: false
1014
secrets:
1115
SF_DEVHUB_URL:
1216
required: true
@@ -20,7 +24,7 @@ jobs:
2024
contents: read
2125
packages: read
2226
env:
23-
SFP_LOG_LEVEL: ${{ vars.SFP_LOG_LEVEL || 'INFO' }}
27+
SFP_LOG_LEVEL: ${{ inputs.loglevel || vars.SFP_LOG_LEVEL || 'INFO' }}
2428
GH_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2529
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2630
SCOPE: ${{ github.repository_owner }}
@@ -70,9 +74,16 @@ jobs:
7074
- name: Download release asset
7175
run: |
7276
curl -L -o release_file.yml -H "Authorization: token ${GH_AUTH_TOKEN}" ${ASSET_URL}
77+
echo "File contents:"
78+
cat release_file.yml
7379
env:
7480
ASSET_URL: "${{ steps.asset.outputs.url }}"
7581

76-
- name: Release to Production
82+
- name: Release to Org
7783
run: |
78-
sfp release --releasedefinition release_file.yml --targetorg targetorg --devhubalias devhub --npm --scope ${SCOPE} --loglevel ${SFP_LOG_LEVEL}
84+
sfp release --releasedefinition release_file.yml \
85+
--targetorg targetorg \
86+
--devhubalias devhub \
87+
--npm \
88+
--scope ${SCOPE} \
89+
--loglevel ${SFP_LOG_LEVEL}

.github/workflows/releaseToDev.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,17 @@ on:
66
description: "Release tag"
77
required: false
88
default: ""
9+
loglevel:
10+
description: "Log level"
11+
required: false
12+
type: choice
13+
options:
14+
- "TRACE"
15+
- "DEBUG"
16+
- "INFO"
17+
- "WARN"
18+
- "ERROR"
19+
- "FATAL"
920
concurrency:
1021
group: ${{ github.workflow }}-${{ github.ref_name }}
1122
jobs:

0 commit comments

Comments
 (0)