improve forked workflow detection #1041
Workflow file for this run
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
name: Lint & Formatting | |
on: | |
pull_request: | |
branches: | |
- main | |
merge_group: | |
defaults: | |
run: | |
shell: bash | |
concurrency: | |
group: ${{ github.ref_name }}-lint-format | |
cancel-in-progress: true | |
permissions: | |
contents: read | |
jobs: | |
format: | |
name: Format | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 | |
- name: Setup Golang Environment | |
uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7 # v5.0.1 | |
with: | |
go-version-file: go.mod | |
- name: Run goimports & gofumpt | |
run: | | |
make format | |
git diff --exit-code | |
lint: | |
name: Lint | |
runs-on: ubuntu-22.04 | |
permissions: | |
contents: read | |
pull-requests: read # for golangci-lint-action | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 | |
- name: Setup Golang Environment | |
uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7 # v5.0.1 | |
with: | |
go-version-file: go.mod | |
- name: Lint Code | |
uses: golangci/golangci-lint-action@9d1e0624a798bb64f6c3cea93db47765312263dc # v5.1.0 | |
with: | |
only-new-issues: true | |
actionlint: | |
name: Actionlint | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 | |
- uses: reviewdog/action-actionlint@51bfb044ddaed55059d16f14daedbe05a9937dc1 # v1.45.0 | |
with: | |
actionlint_flags: -shellcheck "" | |
chart-lint: | |
name: Chart Lint | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 | |
- name: Lint chart | |
run: helm lint charts/nginx-ingress | |
markdown-lint: | |
name: Markdown Lint | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 | |
- uses: DavidAnson/markdownlint-cli2-action@b4c9feab76d8025d1e83c653fa3990936df0e6c8 # v16.0.0 | |
with: | |
config: .markdownlint-cli2.yaml | |
globs: "**/*.md" | |
fix: false |