fix(ci): check WINGET_TOKEN in shell, not in workflow if condition
This commit is contained in:
parent
17691b0c79
commit
ad7ebb312f
1 changed files with 5 additions and 1 deletions
6
.github/workflows/cli-release.yml
vendored
6
.github/workflows/cli-release.yml
vendored
|
|
@ -67,10 +67,14 @@ jobs:
|
|||
```
|
||||
|
||||
- name: Submit winget update
|
||||
if: success() && secrets.WINGET_TOKEN != ''
|
||||
if: success()
|
||||
env:
|
||||
WINGET_TOKEN: ${{ secrets.WINGET_TOKEN }}
|
||||
run: |
|
||||
if [ -z "$WINGET_TOKEN" ]; then
|
||||
echo "WINGET_TOKEN not set, skipping winget update"
|
||||
exit 0
|
||||
fi
|
||||
dotnet tool install --global wingetcreate
|
||||
VERSION="${{ github.ref_name }}"
|
||||
VERSION="${VERSION#cli/v}"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue