FS#57682 - [vim-runtime] Set 'directory' properly
Attached to Project:
Arch Linux
Opened by Ben Burrill (benburrill) - Thursday, 01 March 2018, 03:53 GMT
Last edited by Levente Polyak (anthraxx) - Wednesday, 09 May 2018, 22:44 GMT
Opened by Ben Burrill (benburrill) - Thursday, 01 March 2018, 03:53 GMT
Last edited by Levente Polyak (anthraxx) - Wednesday, 09 May 2018, 22:44 GMT
|
Details
Description:
As suggested in #57640 (but not implemented by da45692), the 'directory' should end in // which makes swap file names more unique (like undodir). Without it, there are issues like https://github.com/vim/vim/issues/2685. :help 'directory' has this to say - For Unix and Win32, if a directory ends in two path separators "//" or "\\", the swap file name will be built from the complete path to the file with all path separators substituted to percent '%' signs. This will ensure file name uniqueness in the preserve directory. I also dislike putting swap files in ~/.vim/swap because it clutters the ~/.vim directory. A potential problem arising from this would be that users inadvertently tracking the swap directory with version control, which has similar (or worse) security implications to CVE-2017-1000382 if they publicly host their vim config. I recommend something like ~/.cache/vim-swap. Vim also has a builtin mkdir() function, which is probably better than using an external tool. Additional info: * package version: 8.0.1542-2 |
This task depends upon
Closed by Levente Polyak (anthraxx)
Wednesday, 09 May 2018, 22:44 GMT
Reason for closing: Fixed
Additional comments about closing: 8.0.1806-1
Wednesday, 09 May 2018, 22:44 GMT
Reason for closing: Fixed
Additional comments about closing: 8.0.1806-1