From 01c85cb7a2813f777bd8449ed6d9ca73183eccc4 Mon Sep 17 00:00:00 2001 From: j-hc Date: Sun, 6 Oct 2024 15:20:16 +0300 Subject: [PATCH] fix get_rv_prebuilts --- utils.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/utils.sh b/utils.sh index 5e34beaa13..448a88d8a3 100755 --- a/utils.sh +++ b/utils.sh @@ -82,8 +82,8 @@ get_rv_prebuilts() { else local for_err=$file if [ "$ver" = "latest" ]; then - file=$(grep -v dev <<<"$file" | head -1) - else file=$(grep "${ver#v}" <<<"$file" | head -1); fi + file=$(grep -v '/[^/]*dev[^/]*$' <<<"$file" | head -1) + else file=$(grep "/[^/]*${ver#v}[^/]*\$" <<<"$file" | head -1); fi if [ -z "$file" ]; then abort "filter fail: '$for_err' with '$ver'"; fi name=$(basename "$file") tag_name=$(cut -d'-' -f3- <<<"$name")