-
Notifications
You must be signed in to change notification settings - Fork 11
39 lines (33 loc) · 1.01 KB
/
build.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
name: Build and deploy
on:
push:
tags:
- '*'
jobs:
test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Install Go
uses: actions/setup-go@v1
with:
go-version: 1.18
- name: Run unit tests
run: make test
- name: Build for all platforms
run: make dist
- name: Push up a new pre-release
if: ${{ contains(github.ref,'pre')}}
env:
GITHUB_TOKEN: ${{ secrets.SECRET_GITHUB_TOKEN }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
run: make prerelease
- name: Push up a new normal release
if: ${{ !contains(github.ref,'pre')}}
env:
GITHUB_TOKEN: ${{ secrets.SECRET_GITHUB_TOKEN }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
run: make release