summaryrefslogtreecommitdiffhomepage
path: root/.github/workflows/go.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/go.yml')
-rw-r--r--.github/workflows/go.yml33
1 files changed, 8 insertions, 25 deletions
diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml
index 3a6a592d1..594dc7ffc 100644
--- a/.github/workflows/go.yml
+++ b/.github/workflows/go.yml
@@ -1,12 +1,16 @@
+# This workflow generates the Go branch. Note that this does not test the Go
+# branch, as this is rolled into the main continuous integration pipeline. This
+# workflow simply generates and pushes the branch, as long as appropriate
+# permissions are available.
name: "Go"
-on:
+"on":
push:
branches:
- master
pull_request:
branches:
- master
- - feature/**
+ - "feature/**"
jobs:
generate:
@@ -37,30 +41,9 @@ jobs:
fetch-depth: 0
- uses: actions/setup-go@v2
with:
- go-version: 1.14
- - uses: actions/cache@v1
- with:
- path: ~/go/pkg/mod
- key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
- restore-keys: |
- ${{ runner.os }}-go-
- - uses: actions/cache@v1
- with:
- path: ~/.cache/bazel
- key: ${{ runner.os }}-bazel-${{ hashFiles('WORKSPACE') }}
- restore-keys: |
- ${{ runner.os }}-bazel-
- # Create gopath to merge the changes. The first execution will create
- # symlinks to the cache, e.g. bazel-bin. Once the cache is setup, delete
- # old gopath files that may exist from previous runs (and could contain
- # files that are now deleted). Then run gopath again for good.
- - run: |
- make build TARGETS="//:gopath"
- rm -rf bazel-bin/gopath
- make build TARGETS="//:gopath"
+ go-version: 1.15
- run: tools/go_branch.sh
- - run: git checkout go && git clean -f
- - run: go build ./...
+ - run: git checkout go && git clean -xf . && go build ./...
- if: github.event_name == 'push'
run: |
git remote add upstream "https://github.com/${{ github.repository }}"