Skip to content

Commit c87740e

Browse files
committed
Added a github action
1 parent 647f8ff commit c87740e

1 file changed

Lines changed: 42 additions & 0 deletions

File tree

.github/workflows/build.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches: [main]
6+
tags: ['v*']
7+
pull_request:
8+
branches: [main]
9+
workflow_dispatch:
10+
11+
jobs:
12+
build:
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
include:
17+
- os: ubuntu-latest
18+
rid: linux-x64
19+
artifact: ClaudeUsageMonitor-linux-x64
20+
- os: windows-latest
21+
rid: win-x64
22+
artifact: ClaudeUsageMonitor-win-x64
23+
24+
runs-on: ${{ matrix.os }}
25+
26+
steps:
27+
- uses: actions/checkout@v4
28+
29+
- name: Setup .NET
30+
uses: actions/setup-dotnet@v4
31+
with:
32+
dotnet-version: '10.0.x'
33+
34+
- name: Publish (AOT)
35+
run: dotnet publish ClaudeUsageMonitor.csproj -c Release -r ${{ matrix.rid }} -o publish/${{ matrix.rid }}
36+
37+
- name: Upload artifact
38+
uses: actions/upload-artifact@v4
39+
with:
40+
name: ${{ matrix.artifact }}
41+
path: publish/${{ matrix.rid }}
42+
if-no-files-found: error

0 commit comments

Comments
 (0)