Update README.md

This commit is contained in:
Darii Nurgaleev 2021-05-06 02:55:59 +07:00 committed by GitHub
parent a71d1eb2c8
commit effa3e26d2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 1 deletions

View File

@ -93,7 +93,7 @@ steps:
- run: dotnet build <my project> - run: dotnet build <my project>
- name: Create the package - name: Create the package
run: dotnet pack --configuration Release <my project> run: dotnet pack --configuration Release <my project>
- name: Publish the package to GPR - name: Publish the package to GPR
run: dotnet nuget push <my project>/bin/Release/*.nupkg run: dotnet nuget push <my project>/bin/Release/*.nupkg
# Authticates packages to push to Azure Artifacts # Authticates packages to push to Azure Artifacts
@ -104,6 +104,15 @@ steps:
NUGET_AUTH_TOKEN: ${{secrets.AZURE_DEVOPS_PAT}} # Note, create a secret with this name in Settings NUGET_AUTH_TOKEN: ${{secrets.AZURE_DEVOPS_PAT}} # Note, create a secret with this name in Settings
- name: Publish the package to Azure Artifacts - name: Publish the package to Azure Artifacts
run: dotnet nuget push <my project>/bin/Release/*.nupkg run: dotnet nuget push <my project>/bin/Release/*.nupkg
# Authticates packages to push to NuGet Org
- uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.x
- name: Publish the package to NuGet Org
run: dotnet nuget push */bin/Release/*.nupkg -k $NUGET_AUTH_TOKEN -s https://api.nuget.org/v3/index.json
env:
NUGET_AUTH_TOKEN: ${{ secrets.NUGET_TOKEN }}
``` ```
## Environment Variables to use with dotnet ## Environment Variables to use with dotnet