From 6c2bf696213dfa31483adbe30add00b849da4545 Mon Sep 17 00:00:00 2001 From: ryenus Date: Tue, 30 Jul 2024 08:07:04 +0800 Subject: [PATCH] rename min_ver to min for consistency --- nvm.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nvm.sh b/nvm.sh index a4f4aed11c6..79c1d6bdbdd 100755 --- a/nvm.sh +++ b/nvm.sh @@ -1837,7 +1837,7 @@ nvm_print_versions() { fi command awk \ - -v remote_versions="$(printf '%s' "${1-}" | tr '\n' '|')" -v min_ver="${NVM_MIN:-v0}" \ + -v remote_versions="$(printf '%s' "${1-}" | tr '\n' '|')" -v min="${NVM_MIN:-v0}" \ -v installed_versions="$(nvm_ls | tr '\n' '|')" -v current="$NVM_CURRENT" \ -v installed_color="$INSTALLED_COLOR" -v system_color="$SYSTEM_COLOR" \ -v current_color="$CURRENT_COLOR" -v default_color="$DEFAULT_COLOR" \ @@ -1860,7 +1860,7 @@ BEGIN { split(remote_versions, lines, "|"); split(installed_versions, installed, "|"); rows = alen(lines); - filter_on = (vcmp("v0.0.0", min_ver) != 0); + filter_on = (vcmp("v0.0.0", min) != 0); current_major = -1; for (m = n = 1; n <= rows; n++) { split(lines[n], fields, "[[:blank:]]+"); @@ -1877,7 +1877,7 @@ BEGIN { if (filter_on != 0) { if (is_installed != 0) { current_major = v2m(version); - } else if (vcmp(version, min_ver) >= 0) { + } else if (vcmp(version, min) >= 0) { filter_on = 0; } else if (v2m(version) != current_major) { continue;