Skip to content

Commit

Permalink
Release package workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
wallymathieu committed Feb 5, 2024
1 parent 37df918 commit 884638a
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/release-package.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Build release package

env:
# Stop wasting time caching packages
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
# Disable sending usage data to Microsoft
DOTNET_CLI_TELEMETRY_OPTOUT: true

on:
push:
tags: ['v**']
jobs:
package:
runs-on: windows-latest
permissions:
packages: write
contents: read
steps:
- uses: actions/checkout@v2
- name: Setup .NET Core
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
8.0.x
7.0.x
6.0.x
- name: Restore
run: git submodule update --init --recursive
- name: Package
run: dotnet pack build.proj
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: nupkg
path: ./bin/nupkg/*.nupkg
- name: Push to GitHub Feed
shell: bash
run: |
for f in ./bin/nupkg/*.nupkg
do
echo $f
dotnet nuget push $f -k ${{ secrets.GITHUB_TOKEN }} -s https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json
done

0 comments on commit 884638a

Please sign in to comment.