runtime(netrw): restore blank line cleanup after file listing
Commit:
https://github.com/vim/vim/commit/b3eaae21b9f681d23466e7caa0b9d7e32cb4b206
Author: uma-chan <[email protected]>
Date: Mon Jul 7 22:04:11 2025 +0200
runtime(netrw): restore blank line cleanup after file listing
Problem: v182 refactoring removed blank line cleanup (g/^$/d) from
s:LocalListing(), causing empty lines between directories
and files.
Solution: Add the missing cleanup after append() in s:PerformListing()
(uma-chan).
closes: #17672
Co-authored-by: Luca Saccarola
<[email protected]>
Signed-off-by: uma-chan <[email protected]>
Signed-off-by: Christian Brabandt <[email protected]>
diff --git a/runtime/pack/dist/opt/netrw/autoload/netrw.vim
b/runtime/pack/dist/opt/netrw/autoload/netrw.vim
index e19d4c4dd..c41285855 100644
--- a/runtime/pack/dist/opt/netrw/autoload/netrw.vim
+++ b/runtime/pack/dist/opt/netrw/autoload/netrw.vim
@@ -7602,6 +7602,8 @@ function s:PerformListing(islocal)
if a:islocal
let filelist = s:NetrwLocalListingList(b:netrw_curdir, 1)
call append(w:netrw_bannercnt - 1, filelist)
+ silent! NetrwKeepj g/^$/d
+ silent! NetrwKeepj %s/
$//e
execute printf("setl ts=%d", g:netrw_maxfilenamelen + 1)
else " remote
NetrwKeepj let badresult= s:NetrwRemoteListing()
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion visit
https://groups.google.com/d/msgid/vim_dev/E1uYsEx-009IdP-Cx%40256bit.org.