-
Notifications
You must be signed in to change notification settings - Fork 12
43 lines (43 loc) · 1.29 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
40
41
42
43
on:
pull_request:
paths:
- "**.go"
- "**.yml"
- "go.mod"
push:
branches:
- master
name: Build PR
jobs:
build:
name: Build binaries
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Fetch Git Tags
run: |
git fetch --prune --unshallow --tags
- name: Get SHORT SHA
id: shortsha
run: |
echo "::set-output name=sha8::$(echo ${{github.event.pull_request.head.sha}} | cut -c1-8)"
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.21'
- name: Cross Platform Build
run: |
export PATH=$PATH:$(go env GOPATH)/bin
make cross
- name: Test
run: |
export PATH=$PATH:$(go env GOPATH)/bin
make test
- name: Report url
shell: bash
run: |
echo "*******************************************************"
echo "https://gopogh.blob.core.windows.net/gopogh/${{github.event.number}}/${{ steps.shortsha.outputs.sha8 }}/output.html"
echo "https://gopogh.blob.core.windows.net/gopogh/${{github.event.number}}/${{ steps.shortsha.outputs.sha8 }}/output.html"
echo "*******************************************************"