mirror of
https://github.com/super-linter/super-linter.git
synced 2024-11-25 23:51:07 -05:00
Specify version flag for kubeconform
Signed-off-by: Brett Logan <lindluni@github.com>
This commit is contained in:
parent
03a3c29f60
commit
c681b09ebe
1 changed files with 10 additions and 8 deletions
|
@ -75,24 +75,26 @@ BuildLinterVersions() {
|
||||||
elif [[ ${LINTER} == "bash-exec" ]] || [[ ${LINTER} == "gherkin-lint" ]] || [[ ${LINTER} == "asl-validator" ]]; then
|
elif [[ ${LINTER} == "bash-exec" ]] || [[ ${LINTER} == "gherkin-lint" ]] || [[ ${LINTER} == "asl-validator" ]]; then
|
||||||
# Need specific command for Protolint and editorconfig-checker
|
# Need specific command for Protolint and editorconfig-checker
|
||||||
GET_VERSION_CMD="$(echo "--version not supported")"
|
GET_VERSION_CMD="$(echo "--version not supported")"
|
||||||
|
elif [[ ${LINTER} == "checkstyle" ]] || [[ ${LINTER} == "google-java-format" ]]; then
|
||||||
|
GET_VERSION_CMD="$(java -jar "/usr/bin/${LINTER}" --version 2>&1)"
|
||||||
|
elif [[ ${LINTER} == "clippy" ]]; then
|
||||||
|
GET_VERSION_CMD="$(cargo-clippy --version 2>&1)"
|
||||||
|
elif [[ ${LINTER} == "editorconfig-checker" ]]; then
|
||||||
|
GET_VERSION_CMD="$(${LINTER} -version)"
|
||||||
|
elif [[ ${LINTER} == "kubeconform" ]]; then
|
||||||
|
GET_VERSION_CMD="$(${LINTER} -v)"
|
||||||
elif [[ ${LINTER} == "lintr" ]]; then
|
elif [[ ${LINTER} == "lintr" ]]; then
|
||||||
# Need specific command for lintr (--slave is deprecated in R 4.0 and replaced by --no-echo)
|
# Need specific command for lintr (--slave is deprecated in R 4.0 and replaced by --no-echo)
|
||||||
GET_VERSION_CMD="$(R --slave -e "r_ver <- R.Version()\$version.string; \
|
GET_VERSION_CMD="$(R --slave -e "r_ver <- R.Version()\$version.string; \
|
||||||
lintr_ver <- packageVersion('lintr'); \
|
lintr_ver <- packageVersion('lintr'); \
|
||||||
glue::glue('lintr { lintr_ver } on { r_ver }')")"
|
glue::glue('lintr { lintr_ver } on { r_ver }')")"
|
||||||
|
elif [[ ${LINTER} == "protolint" ]] || [[ ${LINTER} == "gitleaks" ]]; then
|
||||||
|
GET_VERSION_CMD="$(${LINTER} version)"
|
||||||
elif [[ ${LINTER} == "lua" ]]; then
|
elif [[ ${LINTER} == "lua" ]]; then
|
||||||
# Semi standardversion command
|
# Semi standardversion command
|
||||||
GET_VERSION_CMD="$("${LINTER}" -v 2>&1)"
|
GET_VERSION_CMD="$("${LINTER}" -v 2>&1)"
|
||||||
elif [[ ${LINTER} == "terrascan" ]]; then
|
elif [[ ${LINTER} == "terrascan" ]]; then
|
||||||
GET_VERSION_CMD="$("${LINTER}" version 2>&1)"
|
GET_VERSION_CMD="$("${LINTER}" version 2>&1)"
|
||||||
elif [[ ${LINTER} == "checkstyle" ]] || [[ ${LINTER} == "google-java-format" ]]; then
|
|
||||||
GET_VERSION_CMD="$(java -jar "/usr/bin/${LINTER}" --version 2>&1)"
|
|
||||||
elif [[ ${LINTER} == "clippy" ]]; then
|
|
||||||
GET_VERSION_CMD="$(cargo-clippy --version 2>&1)"
|
|
||||||
elif [[ ${LINTER} == "protolint" ]] || [[ ${LINTER} == "gitleaks" ]]; then
|
|
||||||
GET_VERSION_CMD="$(${LINTER} version)"
|
|
||||||
elif [[ ${LINTER} == "editorconfig-checker" ]]; then
|
|
||||||
GET_VERSION_CMD="$(${LINTER} -version)"
|
|
||||||
else
|
else
|
||||||
# Standard version command
|
# Standard version command
|
||||||
GET_VERSION_CMD="$("${LINTER}" --version 2>&1)"
|
GET_VERSION_CMD="$("${LINTER}" --version 2>&1)"
|
||||||
|
|
Loading…
Reference in a new issue