Skip to content

Commit d4817fc

Browse files
committed
fix publishing
1 parent 26df890 commit d4817fc

1 file changed

Lines changed: 4 additions & 20 deletions

File tree

.github/workflows/main.yml

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,6 @@ on:
1313

1414
env:
1515
DOTNET_NOLOGO: true
16-
GITHUB_FEED: https://nuget.pkg.github.com/ch1seL/
17-
GITHUB_USER: ch1seL
18-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
19-
NUGET_FEED: https://api.nuget.org/v3/index.json
2016
NUGET_KEY: ${{ secrets.NUGET_API_KEY }}
2117

2218
jobs:
@@ -68,21 +64,9 @@ jobs:
6864
echo Version: $VERSION
6965
VERSION="${VERSION//v}"
7066
echo Clean Version: $VERSION
71-
dotnet pack -v normal -c Release --include-symbols --include-source -p:PackageVersion=$VERSION -p:Version=$VERSION -o nupkg
67+
dotnet pack -v normal -c Release --include-symbols --include-source -p:PackageVersion=$VERSION -p:Version=$VERSION
7268
73-
- name: Push to GitHub Feed
74-
working-directory: nupkg
69+
- name: Push to GitHub and Nuget feeds
7570
run: |
76-
for f in *.nupkg
77-
do
78-
curl -vX PUT -u "$GITHUB_USER:$GITHUB_TOKEN" -F package=@$f $GITHUB_FEED
79-
done
80-
81-
- name: Push to NuGet Feed
82-
working-directory: nupkg
83-
run: |
84-
for f in *.nupkg
85-
do
86-
echo $f
87-
dotnet nuget push $f --source $NUGET_FEED --skip-duplicate --api-key $NUGET_KEY
88-
done
71+
dotnet nuget push "src/**/bin/Release/*.nupkg" --source https://api.nuget.org/v3/index.json --api-key $NUGET_KEY --skip-duplicate
72+
dotnet nuget push "src/**/bin/Release/*.nupkg" --source https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json --api-key ${{ github.token }} --skip-duplicate

0 commit comments

Comments
 (0)