Skip to content

Commit

Permalink
Merge pull request #45 from spacemeshos/add-more-checks-to-ci
Browse files Browse the repository at this point in the history
Add more checks to CI
  • Loading branch information
fasmat authored May 8, 2023
2 parents 1b7fa01 + 414e7f4 commit 1566c28
Show file tree
Hide file tree
Showing 17 changed files with 615 additions and 79 deletions.
60 changes: 60 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,52 @@ on:
branches: [main]

jobs:
quicktests:
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- name: checkout
uses: actions/checkout@v3
- name: set up go
uses: actions/setup-go@v4
with:
go-version: ${{ env.go-version }}
- name: install musl
uses: awalsh128/cache-apt-pkgs-action@v1
with:
packages: musl-tools # provides musl-gcc
version: 1.0
- name: fmt, tidy
run: |
make install
make test-fmt
make test-tidy
- name: staticcheck
run: make staticcheck

lint:
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- name: checkout
uses: actions/checkout@v3
- name: set up go
uses: actions/setup-go@v4
with:
go-version: ${{ env.go-version }}
- name: install musl
uses: awalsh128/cache-apt-pkgs-action@v1
with:
packages: musl-tools # provides musl-gcc
version: 1.0
- name: setup env
run: make install
- name: lint
run: make lint-github-action

build:
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- name: checkout
uses: actions/checkout@v3
Expand All @@ -27,5 +71,21 @@ jobs:
version: 1.0
- name: build
run: make build

test:
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- name: checkout
uses: actions/checkout@v3
- name: set up go
uses: actions/setup-go@v4
with:
go-version: ${{ env.go-version }}
- name: install musl
uses: awalsh128/cache-apt-pkgs-action@v1
with:
packages: musl-tools # provides musl-gcc
version: 1.0
- name: go test
run: make test
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# https://github.com/github/gitignore/blob/main/community/Golang/Go.AllowList.gitignore
#
# Binaries for programs and plugins
bin/
*.exe
*.exe~
*.dll
Expand Down
Loading

0 comments on commit 1566c28

Please sign in to comment.