Skip to content

Commit

Permalink
Add release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
NessieHax committed May 6, 2024
1 parent f6c3602 commit b415a96
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Create release

on:
push:
branches: main
tags: v*.*

env:
RELEASE_NAME: PCK-Studio

jobs:
CreateRelease:
runs-on: windows-latest

steps:
- uses: actions/checkout@v4
with:
submodules: recursive

- name: Setup MSBuild
uses: microsoft/setup-msbuild@v2

- name: Setup NuGet
uses: NuGet/setup-nuget@v2

- name: Get NuGet Packages
run: nuget restore PCK_Studio.sln

- name: Build solution
run: "msbuild PCK_Studio.sln -p:Configuration=Release"

- name: Package binary
run: Compress-Archive -Path ${{ github.workspace }}\\bin\\Release\\* -Destination ${{ env.RELEASE_NAME }}.zip

- name: Release
uses: softprops/action-gh-release@v2
if: startsWith(github.ref, 'refs/tags/')
with:
files: ${{ env.RELEASE_NAME }}.zip

0 comments on commit b415a96

Please sign in to comment.