Skip to content

1.0.1

1.0.1 #23

Workflow file for this run

name: Release
on:
workflow_dispatch:
release:
types: [ "published" ]
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Pack
run: ./build.sh pack
shell: bash
- name: Sign Nuget package
env:
NUGET_SIGNING_PFX: ${{ secrets.NUGET_SIGNING_PFX }}
NUGET_ROOT_SIGNING_CERT: ${{ secrets.NUGET_ROOT_SIGNING_CERT }}
run: |
sudo mkdir -p /etc/pki/ca-trust/extracted/pem/
echo "$NUGET_ROOT_SIGNING_CERT" | sudo tee -a /etc/pki/ca-trust/extracted/pem/objsign-ca-bundle.pem > /dev/null
echo "$NUGET_SIGNING_PFX" | openssl base64 -d -out private.pfx
dotnet nuget sign nuget/*.nupkg --certificate-path private.pfx --timestamper http://timestamp.sectigo.com
shell: bash
- name: Publish NuGet package
env:
NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }}
run: dotnet nuget push nuget/*.nupkg --api-key $NUGET_API_KEY --source https://api.nuget.org/v3/index.json
shell: bash
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: LinguaNugetPkg
path: nuget