-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ca48492
commit 9627f01
Showing
4 changed files
with
58 additions
and
63 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: ci | ||
|
||
on: | ||
push: | ||
pull_request: | ||
tags: | ||
- v* | ||
branches: | ||
- 'release/*' | ||
- 'master' | ||
|
||
jobs: | ||
ci: | ||
strategy: | ||
matrix: | ||
arch : [ amd64,arm64 ] | ||
runs-on : ["org--${{ github.repository_owner }}--${{ matrix.arch }}-containers"] | ||
container: ghcr.io/catthehacker/ubuntu:act-22.04 | ||
steps: | ||
- name : Checkout repository | ||
# https://github.com/actions/checkout/releases/tag/v4.1.1 | ||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 | ||
- name: Install Go | ||
# https://github.com/actions/setup-go/releases/tag/v5.0.0 | ||
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0 | ||
with: | ||
go-version-file: 'go.mod' | ||
- name : Install mockgen | ||
run: go install github.com/golang/mock/mockgen@v1.6.0 | ||
- name : Run CI | ||
run: bash scripts/ci | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,37 @@ | ||
name: golangci-lint | ||
# This workflow will build a golang project | ||
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go | ||
|
||
env: | ||
SETUP_GO_VERSION: '^1.20' | ||
name: golint2 | ||
|
||
on: | ||
push: | ||
branches: [ "master" ] | ||
pull_request: | ||
tags: | ||
- v* | ||
branches: | ||
- 'release/*' | ||
- 'master' | ||
branches: [ "master", "release/*" ] | ||
tags: ["v*"] | ||
|
||
jobs: | ||
golangci: | ||
name: golangci-lint | ||
golangci2: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
submodules: recursive | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
submodules: recursive | ||
|
||
- name: Setup Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: ${{ env.SETUP_GO_VERSION }} | ||
- name: Set up Go | ||
uses: actions/setup-go@v4 | ||
with: | ||
go-version-file: go.mod | ||
|
||
- name: Generate Golang | ||
run: | | ||
export PATH=$PATH:/home/runner/go/bin/ | ||
- name: Generate Golang | ||
run: | | ||
export PATH=$PATH:/home/runner/go/bin/ | ||
- name: golangci-lint | ||
uses: golangci/golangci-lint-action@v4.0.0 | ||
with: | ||
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version. | ||
version: v1.55 | ||
- name: Run golangci-lint | ||
uses: golangci/golangci-lint-action@v5.1.0 | ||
with: | ||
# The version of golangci-lint to use. | ||
# When `install-mode` is `binary` (default) the value can be v1.2 or v1.2.3 or `latest` to use the latest version. | ||
# When `install-mode` is `goinstall` the value can be v1.2.3, `latest`, or the hash of a commit. | ||
version: latest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,7 @@ | |
/dist | ||
/build | ||
*.swp | ||
*~ | ||
/.trash-cache | ||
/trash.lock | ||
/.idea | ||
|