ci: run ShellCheck on push only if target branch is main
#1224
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
--- | |
# Documentation: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions | |
name: Lint Code Base | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
permissions: | |
contents: read | |
jobs: | |
build: | |
name: Lint Code Base | |
runs-on: ubuntu-latest | |
steps: | |
- name: Repository checkout | |
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | |
with: | |
fetch-depth: 0 | |
- name: Lint Code Base | |
uses: super-linter/super-linter@3fe03abab2eafb293ace16d4a3b07aeabcb3f1a0 # v6.7.0 | |
env: | |
DEFAULT_BRANCH: main | |
VALIDATE_ALL_CODEBASE: false | |
VALIDATE_BASH: false | |
VALIDATE_BASH_EXEC: false | |
VALIDATE_CHECKOV: false | |
VALIDATE_JSCPD: false | |
VALIDATE_SHELL_SHFMT: false | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |