From 456c26ad9e3526b6f1527ef4e49bc8c77851fc86 Mon Sep 17 00:00:00 2001 From: ghosind Date: Thu, 3 Oct 2024 01:58:07 +0800 Subject: [PATCH] Add -E option to grep command. Signed-off-by: ghosind --- dvm.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dvm.sh b/dvm.sh index 18807a2..34cfa5d 100755 --- a/dvm.sh +++ b/dvm.sh @@ -1110,6 +1110,7 @@ export DVM_VERSION="v0.8.3" fi version_prefix="$version_prefix\." + dvm_debug "searching version prefix: $version_prefix" if ! dvm_get_remote_versions then @@ -1117,7 +1118,7 @@ export DVM_VERSION="v0.8.3" return fi - tmp_versions=$(echo "$DVM_REMOTE_VERSIONS" | grep "$version_prefix" | tail -n 1) + tmp_versions=$(echo "$DVM_REMOTE_VERSIONS" | grep -E "$version_prefix" | tail -n 1) if [ -z "$tmp_versions" ] then dvm_print_error "no version found by $search_text"