-
Notifications
You must be signed in to change notification settings - Fork 28
61 lines (51 loc) · 1.38 KB
/
go.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: Go
on: [push]
jobs:
build:
name: Build
runs-on: ubuntu-22.04
steps:
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '18.17.0'
- name: Set up Go 1.20
uses: actions/setup-go@v4
with:
go-version: '1.20'
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v3
- name: Build static status page
run: cd status-web && yarn && yarn build && cd ../
- name: Get dependencies
run: go mod download && go install github.com/rakyll/statik
- name: Static->GO generation
run: cd cmd/server && statik --src=../../status-web/build/ && cd ../../
- name: Build
run: make
- uses: actions/upload-artifact@v3
with:
name: build-artifact
path: wssocks-*
release:
name: On Release
needs: build
runs-on: ubuntu-22.04
steps:
- uses: actions/download-artifact@v3
with:
name: build-artifact
# - run: ls -R
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
wssocks-linux-amd64
wssocks-linux-arm64
wssocks-darwin-amd64
wssocks-darwin-arm64
wssocks-windows-amd64.exe
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}