Skip to content
This repository has been archived by the owner on Feb 17, 2024. It is now read-only.

Commit

Permalink
refactor build workflow
Browse files Browse the repository at this point in the history
Signed-off-by: Achille Roussel <[email protected]>
  • Loading branch information
achille-roussel committed May 27, 2023
1 parent 4fa2c4a commit f23f693
Showing 1 changed file with 8 additions and 14 deletions.
22 changes: 8 additions & 14 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,16 @@ concurrency:
cancel-in-progress: true

env:
# renovate: datasource=go depName=github.com/golangci/golangci-lint
GOLANGCI_LINT_VERSION: v1.52.2
GOPRIVATE: github.com/stealthrocket
GH_ACCESS_TOKEN: ${{ secrets.PRIVATE_ACCESS_TOKEN }}

jobs:
spellcheck:
name: Spell Check
runs-on: ubuntu-latest
steps:
- name: Checkout Actions Repository
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Check spelling of Go files
uses: crate-ci/typos@master
Expand All @@ -45,21 +44,18 @@ jobs:
go-version-file: go.mod
check-latest: true

- run: git config --global url.https://stealthrocket:[email protected] https://github.com

- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: ${{ env.GOLANGCI_LINT_VERSION }}
version: v1.52.2
args: --timeout 5m

test:
name: Go Test
runs-on: ubuntu-latest
steps:
- name: Configure git for private modules
env:
TOKEN: ${{ secrets.PRIVATE_ACCESS_TOKEN }}
run: git config --global url."https://stealthrocket:${TOKEN}@github.com".insteadOf "https://github.com"

- uses: actions/checkout@v3

- name: Set up Go
Expand All @@ -75,8 +71,6 @@ jobs:
mkdir -p $HOME/gotip
tar -C $HOME/gotip -xzf gotip.tar.gz
- name: Build test programs
run: make testdata GO=$HOME/gotip/bin/go

- name: Test
run: make test
- run: git config --global url.https://stealthrocket:[email protected] https://github.com
- run: make testdata GO=$HOME/gotip/bin/go
- run: make test

0 comments on commit f23f693

Please sign in to comment.