Skip to content

Merge pull request #22 from atc-net/feature/Build-1.0.20.0 #22

Merge pull request #22 from atc-net/feature/Build-1.0.20.0

Merge pull request #22 from atc-net/feature/Build-1.0.20.0 #22

name: "Post-Integration"
on:
push:
branches:
- main
- '!stable'
- '!release'
env:
ATC_EMAIL: '[email protected]'
ATC_NAME: 'Atc-Net'
NUGET_REPO_URL: 'https://nuget.pkg.github.com/atc-net/index.json'
jobs:
merge-to-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 8.0.x
uses: actions/setup-dotnet@v1
with:
dotnet-version: '8.0.x'
- name: ⚙️ Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: 17
distribution: 'zulu'
- 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 with MSBuild
run: |
$vsWhereExePath = "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe"
$vsInstallationPath = & $vsWhereExePath -latest -products * -requires Microsoft.Component.MSBuild -property installationPath
$msBuildExePath = Join-Path $vsInstallationPath "MSBuild\Current\Bin\MSBuild.exe"
& $msBuildExePath Atc.Installer-WithoutSetup.sln -p:Configuration=Release -p:Platform="Any CPU" -m
shell: pwsh
# - name: 🧪 Run unit tests with MSBuild
# run: |
# $vsWhereExePath = "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe"
# $vsInstallationPath = & $vsWhereExePath -latest -products * -requires Microsoft.Component.MSBuild -property installationPath
# $vstestPath = Join-Path $vsInstallationPath "Common7\IDE\CommonExtensions\Microsoft\TestWindow\vstest.console.exe"
# $testAssemblies = (Get-ChildItem -Recurse -Filter *.Test.dll).FullName
# & $vstestPath $testAssemblies
# shell: pwsh
- name: ⏩ Merge to stable-branch
run: |
git config --local user.email ${{ env.ATC_EMAIL }}
git config --local user.name ${{ env.ATC_NAME }}
git checkout stable
git merge --ff-only main
git push origin stable