Skip to content

Commit

Permalink
Add super linter
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredfholgate committed Jul 10, 2024
1 parent e0a3cc0 commit d1297dd
Showing 1 changed file with 49 additions and 0 deletions.
49 changes: 49 additions & 0 deletions .github/workflows/super-linter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
---
name: Linting
on:
pull_request:
types: ['opened', 'synchronize']
merge_group:
workflow_dispatch:

concurrency:
group: linting-${{ github.event.pull_request.head.repo.full_name }}/${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
superlinter:
name: super linter
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Terraform
uses: hashicorp/setup-terraform@v3
with:
terraform_version: latest
terraform_wrapper: false
- name: Run github/super-linter/slim
uses: github/super-linter/slim@v5
env:
# Lint all code
VALIDATE_ALL_CODEBASE: true
FILTER_REGEX_EXCLUDE: '.*tests/vendor/.*'
# Need to define main branch as default
# is set to master in super-linter
DEFAULT_BRANCH: main
# Enable setting the status of each individual linter
# run in the Checks section of a pull request
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# The following linter types will be enabled:
VALIDATE_BASH: true
VALIDATE_BASH_EXEC: true
VALIDATE_GITHUB_ACTIONS: true
VALIDATE_JSON: true
VALIDATE_MARKDOWN: true
# VALIDATE_TERRAFORM_TERRASCAN: true # disabled for now as does not support TF 1.3 optional(type, default)
VALIDATE_TERRAFORM_TFLINT: true
VALIDATE_YAML: true
# VALIDATE_GO: true # Disabled because it down not work :(
# Additional settings:
# If a shell script is not executable, the bash-exec
# linter will report an error when set to true
ERROR_ON_MISSING_EXEC_BIT: true

0 comments on commit d1297dd

Please sign in to comment.