Skip to content

Commit

Permalink
Added ci step for pushing packages to Nuget.org
Browse files Browse the repository at this point in the history
  • Loading branch information
PawelGerr committed Jan 10, 2021
1 parent 98e3980 commit 3aab601
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 8 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,12 @@ jobs:
path: |
out/*.nupkg
out/*.snupkg
- name: push to nuget.org
if: startsWith(github.ref, 'refs/tags/')
run: |
cd out
dotnet nuget push "*.nupkg" -k "$env:API_KEY"
shell: powershell
env:
API_KEY: ${{ secrets.NUGET_ORG_API_KEY }}
17 changes: 9 additions & 8 deletions NuGet.config
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>

<configuration>
<packageSources>
<clear />
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
<add key="dotnet-tools" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-tools/nuget/v3/index.json" />
</packageSources>
<disabledPackageSources>
<clear />
</disabledPackageSources>
<config>
<add key="defaultPushSource" value="https://api.nuget.org/v3/index.json" />
</config>
<packageSources>
<clear />
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
<add key="dotnet-tools" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-tools/nuget/v3/index.json" />
</packageSources>
</configuration>
1 change: 1 addition & 0 deletions Thinktecture.Runtime.Extensions.sln
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "doc", "doc", "{21EB22DE-251
.github\workflows\ci.ps1 = .github\workflows\ci.ps1
.github\workflows\main.yml = .github\workflows\main.yml
.gitignore = .gitignore
NuGet.config = NuGet.config
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "samples", "samples", "{E6F200ED-86D2-4D5C-9D5F-34592908B107}"
Expand Down

0 comments on commit 3aab601

Please sign in to comment.