aboutsummaryrefslogtreecommitdiff
path: root/scripts/vim-patch.sh
diff options
context:
space:
mode:
authorJan Edmund Lazo <janedmundlazo@hotmail.com>2026-08-21 22:42:45 -0400
committerJan Edmund Lazo <janedmundlazo@hotmail.com>2026-08-21 22:42:45 -0400
commit39a7b685395db67dc7f8abafa32f14369ddc8a65 (patch)
tree5740f4303fa1345ddeb3e1a1da9db28e98aa66b4 /scripts/vim-patch.sh
parent03ec1b37d328dbbe47a161c79da873ee7add96c7 (diff)
downloadrneovim-39a7b685395db67dc7f8abafa32f14369ddc8a65.tar.gz
rneovim-39a7b685395db67dc7f8abafa32f14369ddc8a65.tar.bz2
rneovim-39a7b685395db67dc7f8abafa32f14369ddc8a65.zip
feat(vim-patch): ignore vim-patch tokens from commit list
Sort vimpatch_commit_ignore.txt based on "git log" order else "diff" fails to filter out reverted vim-patch tokens. Put latest commit to revert on top of file.
Diffstat (limited to 'scripts/vim-patch.sh')
-rwxr-xr-xscripts/vim-patch.sh12
1 files changed, 7 insertions, 5 deletions
diff --git a/scripts/vim-patch.sh b/scripts/vim-patch.sh
index add2e41c3f..176c78c843 100755
--- a/scripts/vim-patch.sh
+++ b/scripts/vim-patch.sh
@@ -597,15 +597,17 @@ list_vimpatch_tokens() {
# Filter reverted Vim tokens.
list_vimpatch_numbers() {
local patch_pat='(8\.[12]|9\.[0-9])\.[0-9]{1,4}'
- diff "${NVIM_SOURCE_DIR}/scripts/vimpatch_token_reverts.txt" <(
- _git -C "${NVIM_SOURCE_DIR}" log --format="%s%n%b" -E --grep="^[* ]*vim-patch:${patch_pat}" |
+ diff "${NVIM_SOURCE_DIR}/scripts/vimpatch_commit_ignore.txt" <(
+ _git -C "${NVIM_SOURCE_DIR}" log --format="%H" -E --grep="^[* ]*vim-patch:${patch_pat}"
+ ) |
+ grep -e '^> ' |
+ sed -e 's/^> //' |
+ _git -C "${NVIM_SOURCE_DIR}" log --no-walk --stdin --format="%s%n%b" |
grep -oE "^[* ]*vim-patch:${patch_pat}" |
sed -nEe 's/^[* ]*vim-patch:('"${patch_pat}"').*$/\1/p' |
awk '{split($0, a, "."); printf "%d.%d.%04d\n", a[1], a[2], a[3]}' |
sort |
- uniq ) |
- grep -e '^> ' |
- sed -e 's/^> //'
+ uniq
}
declare -A tokens