mirror of
https://github.com/super-linter/super-linter.git
synced 2024-11-22 06:01:05 -05:00
this shoudl be better
This commit is contained in:
parent
1fe8fb5431
commit
dabf5e25c0
2 changed files with 11 additions and 6 deletions
|
@ -871,6 +871,11 @@ Footer() {
|
|||
echo "Reports generated in folder ${REPORT_OUTPUT_FOLDER}"
|
||||
fi
|
||||
|
||||
####################################################
|
||||
# Need to clean up the lanuage array of duplicates #
|
||||
####################################################
|
||||
UNIQUE_LINTED_ARRAY=($(echo "${LINTED_LANGUAGES_ARRAY[@]}" | tr ' ' '\n' | sort -u | tr '\n' ' '))
|
||||
|
||||
##############################
|
||||
# Prints for errors if found #
|
||||
##############################
|
||||
|
@ -899,7 +904,7 @@ Footer() {
|
|||
######################################
|
||||
# Check if we validated the langauge #
|
||||
######################################
|
||||
if [[ "${LINTED_LANGUAGES_ARRAY[@]}" =~ "${LANGUAGE}" ]]; then
|
||||
if [[ "${UNIQUE_LINTED_ARRAY[@]}" =~ "${LANGUAGE}" ]]; then
|
||||
CallStatusAPI "$LANGUAGE" "success"
|
||||
fi
|
||||
fi
|
||||
|
|
|
@ -34,11 +34,6 @@ function LintCodebase() {
|
|||
PRINT_ARRAY+=("----------------------------------------------")
|
||||
PRINT_ARRAY+=("----------------------------------------------")
|
||||
|
||||
#################################
|
||||
# Add the language to the array #
|
||||
#################################
|
||||
LINTED_LANGUAGES_ARRAY+=("$FILE_TYPE")
|
||||
|
||||
#####################################
|
||||
# Validate we have linter installed #
|
||||
#####################################
|
||||
|
@ -173,6 +168,11 @@ function LintCodebase() {
|
|||
echo "---------------------------"
|
||||
echo "File:[$FILE]"
|
||||
|
||||
#################################
|
||||
# Add the language to the array #
|
||||
#################################
|
||||
LINTED_LANGUAGES_ARRAY+=("$FILE_TYPE")
|
||||
|
||||
####################
|
||||
# Set the base Var #
|
||||
####################
|
||||
|
|
Loading…
Reference in a new issue