fix: Ban use of 'test' (#1383)

This commit is contained in:
Edwin Kofler 2022-12-19 05:08:38 -08:00 committed by GitHub
parent 6a4f51a351
commit ec972cbdf0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View File

@ -141,7 +141,7 @@ version_not_installed_text() {
}
get_plugin_path() {
if test -n "$1"; then
if [ -n "$1" ]; then
printf "%s\\n" "$(asdf_data_dir)/plugins/$1"
else
printf "%s\\n" "$(asdf_data_dir)/plugins"

View File

@ -21,6 +21,8 @@ banned_commands=(
# source isn't POSIX compliant. . behaves the same and is POSIX compliant
# Except in fish, where . is deprecated, and will be removed in the future.
source
# For consistency, [ should be used instead. There is a leading space so 'fail_test', etc. is not matched
' test'
)
banned_commands_regex=(