aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2023-09-08 06:56:57 +0800
committerGitHub <noreply@github.com>2023-09-08 06:56:57 +0800
commitacb868bf84246982883b9fc43fee6487be7c7c60 (patch)
tree0306582264b3e7eb182cf16b00fbab07817e86bf
parent3afbf4745bcc9836c0bc5e383a8e46cc16ea8014 (diff)
downloadrneovim-acb868bf84246982883b9fc43fee6487be7c7c60.tar.gz
rneovim-acb868bf84246982883b9fc43fee6487be7c7c60.tar.bz2
rneovim-acb868bf84246982883b9fc43fee6487be7c7c60.zip
build(vim-patch.sh): dereference annotated tags when listing (#25042)
-rwxr-xr-xscripts/vim-patch.sh6
1 files changed, 2 insertions, 4 deletions
diff --git a/scripts/vim-patch.sh b/scripts/vim-patch.sh
index af73a8006a..42b54d6c05 100755
--- a/scripts/vim-patch.sh
+++ b/scripts/vim-patch.sh
@@ -565,10 +565,8 @@ _set_tokens_and_tags() {
# Create an associative array mapping Vim commits to tags.
eval "vim_commit_tags=(
- $(git -C "${VIM_SOURCE_DIR}" for-each-ref refs/tags \
- --format '[%(objectname)]=%(refname:strip=2)' \
- --sort='-*authordate' \
- --shell)
+ $(git -C "${VIM_SOURCE_DIR}" show-ref --tags --dereference \
+ | sed -nEe 's/^([0-9a-f]+) refs\/tags\/(v[0-9.]+)(\^\{\})?$/\1 \2/p')
)"
# Exit in case of errors from the above eval (empty vim_commit_tags).
if ! (( "${#vim_commit_tags[@]}" )); then