Skip to content

Commit

Permalink
merge github workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
angelorc committed Aug 4, 2021
1 parent 26a277a commit 322322e
Showing 1 changed file with 53 additions and 0 deletions.
53 changes: 53 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Publish
on:
push:
tags:
- '*'

jobs:
test:
strategy:
matrix:
go-version: [1.13.x]
os: [ubuntu-latest]
# os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go-version }}

- name: Checkout code
uses: actions/checkout@v2

- uses: actions/cache@v2
with:
# In order:
# * Module download cache
# * Build cache (Linux)
# * Build cache (Mac)
# * Build cache (Windows)
path: |
~/go/pkg/mod
~/.cache/go-build
~/Library/Caches/go-build
%LocalAppData%\go-build
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Load deps
run: make go-mod-cache

- name: Build code
run: make build

- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: build/*
tag: ${{ github.ref }}
overwrite: true
file_glob: true

0 comments on commit 322322e

Please sign in to comment.