Skip to content

Commit 9bf9279

Browse files
committed
Fix build
1 parent e9da1e0 commit 9bf9279

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

.github/workflows/dotnet.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,19 @@ jobs:
4444
path: "artifacts/**/*nupkg"
4545
if-no-files-found: warn
4646
retention-days: 1
47+
- name: Determine whether we should push to experimental feed.
48+
id: check_token
49+
run: |
50+
if [ -z "${{ secrets.EXP_NUGET_PASSWORD }}" ]; then
51+
echo "push=false" >> $GITHUB_OUTPUT
52+
else
53+
echo "push=true" >> $GITHUB_OUTPUT
54+
fi
4755
- name: Push to Experimental Feed
48-
if: ${{ secrets.EXP_NUGET_PASSWORD != '' }}
56+
if: ${{ steps.check_token.outputs.push == 'true' }}
4957
run: ./build.sh PushToNuGet --skip Clean Compile Pack --nuget-feed https://dotnet.github.io/Silk.NET/nuget/experimental/index.json --nuget-username ${{ secrets.EXP_NUGET_USERNAME }} --nuget-password ${{ secrets.EXP_NUGET_PASSWORD }} --nuget-api-key ${{ secrets.EXP_NUGET_PASSWORD }}
5058
- name: Push to GitHub Packages
51-
if: ${{ secrets.EXP_NUGET_PASSWORD != '' }} # ik it's irrelevant but it tells if we likely have perms
59+
if: ${{ steps.check_token.outputs.push == 'true' }}
5260
run: ./build.sh PushToNuGet --skip Clean Compile Pack --nuget-feed https://nuget.pkg.github.com/dotnet/index.json --nuget-api-key ${{ secrets.GITHUB_TOKEN }}
5361
Test:
5462
strategy:

0 commit comments

Comments
 (0)