File tree Expand file tree Collapse file tree 1 file changed +36
-0
lines changed
Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Build the binary and create release
2+
3+ on :
4+ workflow_dispatch :
5+ pull_request :
6+ push :
7+ tags :
8+ - ' **'
9+
10+ jobs :
11+ build-and-release :
12+ runs-on : ubuntu-latest
13+ permissions :
14+ contents : write
15+
16+ steps :
17+ - name : Checkout the repository
18+ uses : actions/checkout@v4
19+
20+ - name : Setup Go
21+ uses : actions/setup-go@v5
22+ with :
23+ go-version : ' 1.21'
24+
25+ - name : Build the binary for linux/amd64
26+ working-directory : teamup-rocketchat-bot
27+ # run: GOARCH=amd64 GOOS=linux go build -o build/linux-amd64-${{ github.ref_name }} .
28+ run : GOARCH=amd64 GOOS=linux go build -o build/linux-amd64 .
29+
30+ - name : Create GitHub release and upload binary
31+ uses : softprops/action-gh-release@v2
32+ with :
33+ # files: teamup-rocketchat-bot/build/linux-amd64-${{ github.ref_name }}
34+ files : teamup-rocketchat-bot/build/linux-amd64
35+ env :
36+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments