Skip to content

Merge pull request #10 from atc-net/feature/Fix-unpacking #10

Merge pull request #10 from atc-net/feature/Fix-unpacking

Merge pull request #10 from atc-net/feature/Fix-unpacking #10

Workflow file for this run

name: "Release"
on:
push:
branches:
- main
# on:
# workflow_dispatch:
env:
ATC_EMAIL: '[email protected]'
ATC_NAME: 'Atc-Net'
NUGET_REPO_URL: 'https://api.nuget.org/v3/index.json'
jobs:
release:
if: github.ref == 'refs/heads/stable'
runs-on: windows-latest
steps:
- name: 🛒 Checkout repository
uses: actions/checkout@v2
with:
fetch-depth: 0
token: ${{ secrets.PAT_WORKFLOWS }}
- name: ⚛️ Sets environment variables - branch-name
uses: nelonoel/[email protected]
- name: ⚛️ Sets environment variables - Nerdbank.GitVersioning
uses: dotnet/nbgv@master
with:
setAllVars: true
- name: ⚙️ Setup dotnet 7.0.x
uses: actions/setup-dotnet@v1
with:
dotnet-version: '7.0.x'
- name: 📐 Ensure nuget.org added as package source on Windows
run: dotnet nuget add source https://api.nuget.org/v3/index.json -n nuget.org --configfile $env:APPDATA\NuGet\NuGet.Config
continue-on-error: true
- name: 🔁 Restore packages
run: dotnet restore Atc.Installer-WithoutSetup.sln
- name: 🛠️ Building library in release mode
run: dotnet build Atc.Installer-WithoutSetup.sln -c Release --no-restore /p:UseSourceLink=true
- name: ⏩ Merge to release-branch
run: |
git config --local user.email ${{ env.ATC_EMAIL }}
git config --local user.name ${{ env.ATC_NAME }}
git checkout release
git merge --ff-only stable
git push origin release
- name: 🗳️ Creating library package for release
run: dotnet pack Atc.Installer-WithoutSetup.sln -c Release --no-restore -o ${GITHUB_WORKSPACE}/packages -p:RepositoryBranch=$BRANCH_NAME /p:PublicRelease=true