mirror of
https://github.com/super-linter/super-linter.git
synced 2024-12-22 12:42:09 -05:00
[Snakemake] Add '--config' parameter to 'snakefmt' calls
This commit is contained in:
parent
0c5029bf67
commit
53f551c8b0
2 changed files with 5 additions and 4 deletions
|
@ -118,6 +118,9 @@ R_LINTER_RULES="${DEFAULT_RULES_LOCATION}/${R_FILE_NAME}"
|
|||
# Ruby Vars
|
||||
RUBY_FILE_NAME="${RUBY_CONFIG_FILE:-.ruby-lint.yml}" # Name of the file
|
||||
RUBY_LINTER_RULES="${DEFAULT_RULES_LOCATION}/${RUBY_FILE_NAME}" # Path to the ruby lint rules
|
||||
# Snakemake Vars
|
||||
SNAKEMAKE_FILE_NAME="${SNAKEMAKE_CONFIG_FILE:-.snakefmt.toml}"
|
||||
SNAKEMAKE_LINTER_RULES="${DEFAULT_RULES_LOCATION}/${SNAKEMAKE_FILE_NAME}"
|
||||
# SQL Vars
|
||||
SQL_FILE_NAME=".sql-config.json" # Name of the file
|
||||
SQL_LINTER_RULES="${DEFAULT_RULES_LOCATION}/${SQL_FILE_NAME}" # Path to the SQL lint rules
|
||||
|
@ -1855,9 +1858,7 @@ if [ "${VALIDATE_SNAKEMAKE}" == "true" ]; then
|
|||
# Lint the files with snakefmt #
|
||||
################################
|
||||
# LintCodebase "FILE_TYPE" "LINTER_NAME" "LINTER_CMD" "FILE_TYPES_REGEX" "FILE_ARRAY"
|
||||
LintCodebase "SNAKEMAKE" "snakefmt" "snakefmt --diff" ".*\.\(smk\)\$" "${FILE_ARRAY_SNAKEMAKE[@]}"
|
||||
|
||||
# TODO: add --config <path>
|
||||
LintCodebase "SNAKEMAKE" "snakefmt" "snakefmt --config ${SNAKEMAKE_LINTER_RULES} --diff" ".*\.\(smk\)\$" "${FILE_ARRAY_SNAKEMAKE[@]}"
|
||||
fi
|
||||
|
||||
######################
|
||||
|
|
|
@ -702,7 +702,7 @@ function RunTestCases() {
|
|||
TestCodebase "RAKU" "raku" "raku -c" ".*\.\(raku\|rakumod\|rakutest\|pm6\|pl6\|p6\)\$" "raku"
|
||||
TestCodebase "RUBY" "rubocop" "rubocop -c ${RUBY_LINTER_RULES}" ".*\.\(rb\)\$" "ruby"
|
||||
TestCodebase "SHELL_SHFMT" "shfmt" "shfmt -d" ".*\.\(sh\|bash\|dash\|ksh\)\$" "shell_shfmt"
|
||||
TestCodebase "SNAKEMAKE" "snakefmt" "snakefmt --diff" ".*\.\(smk\)\$" "snakemake"
|
||||
TestCodebase "SNAKEMAKE" "snakefmt" "snakefmt --config ${SNAKEMAKE_LINTER_RULES} --diff" ".*\.\(smk\)\$" "snakemake"
|
||||
TestCodebase "STATES" "asl-validator" "asl-validator --json-path" ".*\.\(json\)\$" "states"
|
||||
TestCodebase "SQL" "sql-lint" "sql-lint --config ${SQL_LINTER_RULES}" ".*\.\(sql\)\$" "sql"
|
||||
TestCodebase "TERRAFORM" "tflint" "tflint -c ${TERRAFORM_LINTER_RULES}" ".*\.\(tf\)\$" "terraform"
|
||||
|
|
Loading…
Reference in a new issue