mirror of
https://github.com/kubesphere/kubekey.git
synced 2025-12-25 17:12:50 +00:00
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 6. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v3...v6) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
82 lines
1.6 KiB
YAML
82 lines
1.6 KiB
YAML
name: GolangCILint
|
|
|
|
on:
|
|
pull_request:
|
|
types: [opened, edited, synchronize, reopened]
|
|
paths:
|
|
- 'pkg/**'
|
|
- 'cmd/**'
|
|
- 'version/**'
|
|
- 'go.mod'
|
|
- 'go.sum'
|
|
- 'api/**'
|
|
|
|
# Remove all permissions from GITHUB_TOKEN except metadata.
|
|
permissions: {}
|
|
|
|
jobs:
|
|
golangci:
|
|
name: lint
|
|
runs-on: ubuntu-latest
|
|
if: github.repository == 'kubesphere/kubekey'
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v6
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Setup golang
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: 1.23.3
|
|
|
|
- name: Sync mod
|
|
run: make generate-modules
|
|
|
|
- name: golangci-lint
|
|
uses: golangci/golangci-lint-action@v6
|
|
with:
|
|
version: v1.63.3
|
|
|
|
verify:
|
|
name: verify
|
|
runs-on: ubuntu-latest
|
|
if: github.repository == 'kubesphere/kubekey'
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v6
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Setup golang
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: 1.23.3
|
|
|
|
- name: Sync mod
|
|
run: make generate-modules
|
|
|
|
- name: Verify
|
|
run: ALL_VERIFY_CHECKS="goimports releaser" make verify
|
|
|
|
test:
|
|
name: test
|
|
runs-on: ubuntu-latest
|
|
if: github.repository == 'kubesphere/kubekey'
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v6
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Setup golang
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: 1.23.3
|
|
|
|
- name: Sync mod
|
|
run: make generate-modules
|
|
|
|
- name: Test
|
|
run: make test
|