I have trouble with buffers in Vim (8.0 on a rhel8 server) apparently. That said ... I was not aware of the exitance of buffers before facing this problem. So as you can see, my expertise in vim is limited.
I got in contact via en error poppig up when tring to
:q a file which I am allowed to edit via
systemctl edit --full postgresql@.service which uses vim to edit
/etc/systemd/system/postgresql@.service. Due to restrictions in my environment I do not have any write access beyond that in
E173: 2 more files to edit
so I learned that buffers may be my problem
:ls 1 %a "/email@example.com" line 1 2 "/firstname.lastname@example.org" line 0 3 "/email@example.com" line 0
now ... I found that
:%bd should be the way to getting rid of those. However it does not work.
3 buffers deleted and shows an empty file. It I try to get out of this
:q I am getting a new
E173 2 more files to edit. the only way getting out of this is a
Entering the file I wanted to work on again shows
:ls 1 %a "/firstname.lastname@example.org" line 1 2 "/email@example.com" line 0 3 "/firstname.lastname@example.org" line 0
so I am back to where I startet.
Is it the restricted access to the location of that file I am trying to work on, which may prevent the buffers from being deleted? Is there any way around this?
I may be worth mentioning that apparently files listed in the buffers list (i.e.
) do not exist.
$ ls -la /etc/systemd/system/postgresql@*.service* -rw-r--r--. 1 root root 965 21. Sep 10:08 /email@example.com -rw-r--r--. 1 root root 933 21. Sep 09:18 /firstname.lastname@example.org -rw-r--r--. 1 root root 938 9. Sep 15:25 /etc/systemd/system/postgresql@.service -rw-r--r--. 1 root root 922 21. Sep 09:16 /email@example.com
also a swap file matching somewhat that naming schema (