Update dotnetcore.yml #52
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: GitHub packages NuGet generation | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: windows-latest | |
name: Update NuGet | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@master | |
- name: Build solution and generate NuGet package | |
run: | | |
cd src\netstandard\ | |
dotnet pack -c Release -o out /p:Version="${{ secrets.PACKAGE_VERSION }}-develop-${{ github.run_number }}" | |
- name: Install NuGet client | |
uses: nuget/setup-nuget@v1 | |
- name: Add private GitHub registry to NuGet | |
run: nuget sources add -name "GPR" -Source https://nuget.pkg.github.com/Code-Sharp/index.json -Username Code-Sharp -Password ${{ secrets.GITHUB_TOKEN }} | |
- name: Push generated package to GitHub registry | |
run: | | |
cd src\netstandard\ | |
nuget push .\out\*.nupkg -Source "GPR" -SkipDuplicate |