File tree Expand file tree Collapse file tree 4 files changed +136
-70
lines changed
Expand file tree Collapse file tree 4 files changed +136
-70
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ name : Release Linux Build
2+ permissions :
3+ contents : write
4+
5+ on :
6+ push :
7+ tags :
8+ - " *"
9+ jobs :
10+ release :
11+ runs-on : ubuntu-latest
12+ steps :
13+ - name : Checkout code
14+ uses : actions/checkout@v4
15+ with :
16+ fetch-depth : 0
17+ - name : Setup Node
18+ uses : actions/setup-node@v4
19+ with :
20+ node-version : " 20.x"
21+ cache : " npm"
22+ cache-dependency-path : " web/package-lock.json"
23+ - name : Build Frontend
24+ run : npm install && VITE_VERSION=${{ github.ref_name }} npm run build
25+ working-directory : ./web
26+ - name : Setup Go
27+ uses : actions/setup-go@v5
28+ with :
29+ go-version : " 1.23.x"
30+ - name : Build Backend for amd64
31+ run : |
32+ go mod download
33+ go build -ldflags "-s -w -X gpt-load/internal/version.Version=${{ github.ref_name }}" -o gpt-load
34+ - name : Build Backend for arm64
35+ run : |
36+ CGO_ENABLED=0 GOOS=linux GOARCH=arm64 go build -ldflags "-s -w -X gpt-load/internal/version.Version=${{ github.ref_name }}" -o gpt-load-arm64
37+ - name : Release
38+ uses : softprops/action-gh-release@v1
39+ if : startsWith(github.ref, 'refs/tags/')
40+ with :
41+ files : |
42+ gpt-load
43+ gpt-load-arm64
44+ draft : true
45+ generate_release_notes : true
46+ env :
47+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change 1+ name : Release MacOS Build
2+ permissions :
3+ contents : write
4+
5+ on :
6+ push :
7+ tags :
8+ - " *"
9+ jobs :
10+ release :
11+ runs-on : macos-latest
12+ steps :
13+ - name : Checkout code
14+ uses : actions/checkout@v4
15+ with :
16+ fetch-depth : 0
17+ - name : Setup Node
18+ uses : actions/setup-node@v4
19+ with :
20+ node-version : " 20.x"
21+ cache : " npm"
22+ cache-dependency-path : " web/package-lock.json"
23+ - name : Build Frontend
24+ run : npm install && VITE_VERSION=${{ github.ref_name }} npm run build
25+ working-directory : ./web
26+ - name : Setup Go
27+ uses : actions/setup-go@v5
28+ with :
29+ go-version : " 1.23.x"
30+ - name : Build Backend
31+ run : |
32+ go mod download
33+ go build -ldflags "-s -w -X gpt-load/internal/version.Version=${{ github.ref_name }}" -o gpt-load-macos
34+ - name : Release
35+ uses : softprops/action-gh-release@v1
36+ if : startsWith(github.ref, 'refs/tags/')
37+ with :
38+ files : |
39+ gpt-load-macos
40+ draft : true
41+ generate_release_notes : true
42+ env :
43+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change 1+ name : Release Windows Build
2+ permissions :
3+ contents : write
4+
5+ on :
6+ push :
7+ tags :
8+ - " *"
9+ jobs :
10+ release :
11+ runs-on : windows-latest
12+ defaults :
13+ run :
14+ shell : bash
15+ steps :
16+ - name : Checkout code
17+ uses : actions/checkout@v4
18+ with :
19+ fetch-depth : 0
20+ - name : Setup Node
21+ uses : actions/setup-node@v4
22+ with :
23+ node-version : " 20.x"
24+ cache : " npm"
25+ cache-dependency-path : " web/package-lock.json"
26+ - name : Build Frontend
27+ run : npm install && VITE_VERSION=${{ github.ref_name }} npm run build
28+ working-directory : ./web
29+ - name : Setup Go
30+ uses : actions/setup-go@v5
31+ with :
32+ go-version : " 1.23.x"
33+ - name : Build Backend
34+ run : |
35+ go mod download
36+ go build -ldflags "-s -w -X gpt-load/internal/version.Version=${{ github.ref_name }}" -o gpt-load.exe
37+ - name : Release
38+ uses : softprops/action-gh-release@v1
39+ if : startsWith(github.ref, 'refs/tags/')
40+ with :
41+ files : |
42+ gpt-load.exe
43+ draft : true
44+ generate_release_notes : true
45+ env :
46+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments