Skip to content

Commit a07bfff

Browse files
committed
Added release workflow that builds both x64 and ARM64
1 parent f276d84 commit a07bfff

1 file changed

Lines changed: 51 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: Release Taskmon
2+
on:
3+
push:
4+
tags:
5+
- 'v*.*.*'
6+
workflow_dispatch:
7+
permissions:
8+
contents: write
9+
jobs:
10+
build:
11+
runs-on: windows-latest
12+
strategy:
13+
matrix:
14+
arch: [x64, ARM64]
15+
steps:
16+
- name: Checkout Code
17+
uses: actions/checkout@v4
18+
- name: Configure CMake
19+
run: cmake -B build -A ${{ matrix.arch }}
20+
- name: Build
21+
run: cmake --build build --config Release
22+
- name: Rename Binary
23+
shell: pwsh
24+
run: |
25+
$arch = "${{ matrix.arch }}".ToLower()
26+
Move-Item build/Release/taskmon.exe build/Release/taskmon-$arch.exe
27+
- name: Upload Artifacts
28+
uses: actions/upload-artifact@v4
29+
with:
30+
name: taskmon-${{ matrix.arch }}
31+
path: build/Release/taskmon-*.exe
32+
release:
33+
needs: build
34+
runs-on: ubuntu-latest
35+
steps:
36+
- name: Download all artifacts
37+
uses: actions/download-artifact@v4
38+
with:
39+
path: ./artifacts
40+
- name: List artifacts
41+
run: ls -R ./artifacts
42+
- name: Create Release
43+
uses: softprops/action-gh-release@v2
44+
with:
45+
tag_name: ${{ github.ref_name }}
46+
name: Taskmon Release ${{ github.ref_name }}
47+
draft: false
48+
prerelease: false
49+
files: |
50+
./artifacts/taskmon-x64/taskmon-x64.exe
51+
./artifacts/taskmon-ARM64/taskmon-arm64.exe

0 commit comments

Comments
 (0)