Skip to content

Commit d8c8833

Browse files
Publish to feedz.io
Publish NuGet packages built on main or from tags to feedz.io.
1 parent d418b5a commit d8c8833

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

.github/workflows/ci.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,3 +119,34 @@ jobs:
119119
Write-Output "::error::$invalidPackages NuGet package(s) failed validation."
120120
exit 1
121121
}
122+
123+
publish-feedz-io:
124+
needs: [ build-test, validate-packages ]
125+
runs-on: ubuntu-latest
126+
if: |
127+
github.event.repository.fork == false &&
128+
(github.ref_name == github.event.repository.default_branch || startsWith(github.ref, 'refs/tags/'))
129+
130+
environment:
131+
name: feedz.io
132+
133+
steps:
134+
135+
- name: Download packages
136+
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
137+
with:
138+
name: packages-windows
139+
140+
- name: Setup .NET SDK
141+
uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4.3.1
142+
with:
143+
dotnet-version: ${{ needs.build-test.outputs.dotnet-sdk-version }}
144+
145+
# TODO Get the feedz.io token from Vault
146+
147+
- name: Push NuGet packages to feedz.io
148+
shell: bash
149+
env:
150+
API_KEY: ${{ env.FEEDZ_IO_TOKEN }}
151+
SOURCE: 'https://f.feedz.io/${{ github.repository }}/nuget/index.json'
152+
run: dotnet nuget push "*.nupkg" --api-key "${API_KEY}" --skip-duplicate --source "${SOURCE}"

0 commit comments

Comments
 (0)