Skip to content

Commit

Permalink
Use artifacts dir and add NuGet package source mapping
Browse files Browse the repository at this point in the history
  • Loading branch information
brantburnett committed Dec 16, 2024
1 parent b46f88d commit f288628
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,4 +147,4 @@ jobs:
run: dotnet pack --configuration Release -p:Version=${{ steps.version.outputs.version }}
- name: Push to NuGet.org
run: |
dotnet nuget push **/*.nupkg --api-key ${{ secrets.NUGET_API_KEY}} --source https://api.nuget.org/v3/index.json
dotnet nuget push artifacts/package/**/*.nupkg --api-key ${{ secrets.NUGET_API_KEY}} --source https://api.nuget.org/v3/index.json
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
[Oo]bj/
[Bb]in/
artifacts/
packages/
*.suo
*.user
Expand Down
1 change: 1 addition & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
<PropertyGroup>
<LangVersion>13</LangVersion>
<CheckEolTargetFramework>false</CheckEolTargetFramework>
<UseArtifactsOutput>true</UseArtifactsOutput>
</PropertyGroup>
</Project>
15 changes: 15 additions & 0 deletions nuget.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<!--To inherit the global NuGet package sources remove the <clear/> line below -->
<clear />
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
</packageSources>

<packageSourceMapping>
<!-- key value for <packageSource> should match key values from <packageSources> element -->
<packageSource key="nuget.org">
<package pattern="*" />
</packageSource>
</packageSourceMapping>
</configuration>

0 comments on commit f288628

Please sign in to comment.