Advertisement
therube

vim write to nul device without bugging

Feb 19th, 2020
422
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.85 KB | None | 0 0
  1. <therube_agone> hi. i'm on windows. i'm try to write to the "device", nul.
  2. <therube_agone> i do something like; 'a,w nul
  3. <therube_agone> i use that a lot to get a count of lines between "marks" ('a,.)
  4. <therube_agone> i /used/ to be able to do that without issue, but that changed in later versions of Vim
  5. <therube_agone> with (i think with) v8.1, i had to; set opendevice & then still had to force the write; 'a,w! nul
  6. <therube_agone> with 8.2, i'm getting E768: Swap file exits: C:\Local\Vim_BAK\nul.swp (:silent! overrides)
  7. <therube_agone> i'm not looking to overwrite nul.swp (which does not even exist), i just trying to write to the nul device, nul
  8. <therube_agone> there is a currently.opened.filename.txt.swp in the Vim_BAK directory
  9. <therube_agone> pointers ?
  10. <therube_agone> i have also set backupdir, directory, & undodir to that same Vim_BAK
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement