Skip to content

Merge pull request #4 from BytexGrid/patch #60

Merge pull request #4 from BytexGrid/patch

Merge pull request #4 from BytexGrid/patch #60

Workflow file for this run

name: Release
on:
push:
tags:
- "v*"
permissions:
contents: write
packages: read # for package dependencies
actions: read # for checking out code
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/[email protected]
- name: Setup .NET
uses: actions/[email protected]
with:
dotnet-version: 6.0.x
- name: Restore dependencies
working-directory: ./NeatShift
run: dotnet restore NeatShift.sln
- name: Build
working-directory: ./NeatShift
run: dotnet build NeatShift.sln --configuration Release --no-restore
- name: Publish
working-directory: ./NeatShift
run: |
dotnet publish "NeatShift/NeatShift.csproj" -c Release -r win-x64 `
--self-contained true `
-p:PublishSingleFile=true `
-p:EnableCompressionInSingleFile=true `
-p:IncludeNativeLibrariesForSelfExtract=true `
-p:DebugType=None `
-p:DebugSymbols=false `
-p:PublishReadyToRun=true `
-p:PublishTrimmed=false `
-p:ApplicationManifest=app.manifest `
-p:WindowsPackageType=None `
-p:IncludeAllContentForSelfExtract=true `
-o ../publish
- name: Copy exe to release
run: Copy-Item "publish/NeatShift.exe" -Destination "NeatShift.exe"
- name: Create Runtime Config
run: |
Set-Content -Path "publish/NeatShift.runtimeconfig.json" -Value '{
"runtimeOptions": {
"tfm": "net6.0-windows",
"framework": {
"name": "Microsoft.WindowsDesktop.App",
"version": "6.0.0"
},
"configProperties": {
"System.Reflection.Metadata.MetadataUpdater.IsSupported": false
}
}
}'
- name: Zip Release with Config
run: Compress-Archive -Path "publish/*" -DestinationPath "NeatShift-Release.zip"
- name: Create Release
uses: softprops/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
files: |
NeatShift.exe
NeatShift-Release.zip
draft: false
prerelease: false
generate_release_notes: true