From 19abf45423b2635993dba40bf1b86fa329f0cb45 Mon Sep 17 00:00:00 2001 From: Barry Pollard Date: Mon, 24 Jan 2022 15:01:37 +0000 Subject: [PATCH] Correct SQLFluff config filename (#2366) --- .github/linters/{.sqlfluffini => .sqlfluff} | 0 README.md | 2 +- TEMPLATES/{.sqlfluffini => .sqlfluff} | 2 +- lib/linter.sh | 2 +- test/inspec/super-linter/controls/super_linter.rb | 2 +- 5 files changed, 4 insertions(+), 4 deletions(-) rename .github/linters/{.sqlfluffini => .sqlfluff} (100%) rename TEMPLATES/{.sqlfluffini => .sqlfluff} (98%) diff --git a/.github/linters/.sqlfluffini b/.github/linters/.sqlfluff similarity index 100% rename from .github/linters/.sqlfluffini rename to .github/linters/.sqlfluff diff --git a/README.md b/README.md index d6c9a101..ad9d5725 100644 --- a/README.md +++ b/README.md @@ -316,7 +316,7 @@ But if you wish to select or exclude specific linters, we give you full control | **SNAKEMAKE_SNAKEFMT_CONFIG_FILE** | `.snakefmt.toml` | Filename for [Snakemake configuration](https://github.com/snakemake/snakefmt#configuration) (ex: `pyproject.toml`, `.snakefmt.toml`) | | **SSL_CERT_SECRET** | `none` | SSL cert to add to the **Super-Linter** trust store. This is needed for users on `self-hosted` runners or need to inject the cert for security standards (ex. ${{ secrets.SSL_CERT }}) | | **SQL_CONFIG_FILE** | `.sql-config.json` | Filename for [SQL-Lint configuration](https://sql-lint.readthedocs.io/en/latest/files/configuration.html) (ex: `sql-config.json` , `.config.json`) | -| **SQLFLUFF_CONFIG_FILE** | `.sqlfluffini` | Filename for [SQLFLUFF configuration](https://docs.sqlfluff.com/en/stable/configuration.html) (ex: `.sqlfluffini`, `pyproject.toml`) | +| **SQLFLUFF_CONFIG_FILE** | `/.sqlfluff` | Filename for [SQLFLUFF configuration](https://docs.sqlfluff.com/en/stable/configuration.html) (ex: `/.sqlfluff`, `pyproject.toml`) | | **SUPPRESS_FILE_TYPE_WARN** | `false` | If set to `true`, will hide warning messages about files without their proper extensions. Default is `false` | | **SUPPRESS_POSSUM** | `false` | If set to `true`, will hide the ASCII possum at top of log output. Default is `false` | | **TERRAFORM_TERRASCAN_CONFIG_FILE**| `terrascan.toml` | Filename for [terrascan configuration](https://github.com/accurics/terrascan) (ex: `terrascan.toml`) | diff --git a/TEMPLATES/.sqlfluffini b/TEMPLATES/.sqlfluff similarity index 98% rename from TEMPLATES/.sqlfluffini rename to TEMPLATES/.sqlfluff index 7ca2ab49..560e0e81 100644 --- a/TEMPLATES/.sqlfluffini +++ b/TEMPLATES/.sqlfluff @@ -1,4 +1,4 @@ -## This .sqlfluffini file can be used to configure the SQLFluff linter when +## This /.sqlfluff file can be used to configure the SQLFluff linter when ## used via the GitHub Super Linter. Copy it to the .github/linters folder of ## your repo, and uncomment the necessary lines to configure the Super Linter. ## diff --git a/lib/linter.sh b/lib/linter.sh index 7d33d310..36651da1 100755 --- a/lib/linter.sh +++ b/lib/linter.sh @@ -172,7 +172,7 @@ SUPPRESS_POSSUM="${SUPPRESS_POSSUM:-false}" # shellcheck disable=SC2034 # Variable is referenced indirectly SQL_FILE_NAME="${SQL_CONFIG_FILE:-.sql-config.json}" # shellcheck disable=SC2034 # Variable is referenced indirectly -SQLFLUFF_FILE_NAME="${SQLFLUFF_CONFIG_FILE:-.sqlfluffini}" +SQLFLUFF_FILE_NAME="${SQLFLUFF_CONFIG_FILE:-/.sqlfluff}" # shellcheck disable=SC2034 # Variable is referenced indirectly TERRAFORM_TFLINT_FILE_NAME="${TERRAFORM_TFLINT_CONFIG_FILE:-.tflint.hcl}" # shellcheck disable=SC2034 # Variable is referenced indirectly diff --git a/test/inspec/super-linter/controls/super_linter.rb b/test/inspec/super-linter/controls/super_linter.rb index 261d894e..c0b2d791 100644 --- a/test/inspec/super-linter/controls/super_linter.rb +++ b/test/inspec/super-linter/controls/super_linter.rb @@ -392,7 +392,7 @@ control "super-linter-validate-files" do "/action/lib/.automation/.scalafmt.conf", "/action/lib/.automation/.snakefmt.toml", "/action/lib/.automation/.sql-config.json", - "/action/lib/.automation/.sqlfluffini", + "/action/lib/.automation//.sqlfluff", "/action/lib/.automation/.stylelintrc.json", "/action/lib/.automation/.tflint.hcl", "/action/lib/.automation/.yaml-lint.yml",