Skip to main content
OverflowAI is here! AI power for your Stack Overflow for Teams knowledge community. Learn more

Questions tagged [filesystem]

For questions regarding searching and navigating the filesystem.

12 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
4 votes
0 answers
537 views

vimscript - copy a file from one path to another

How do I rewrite this line of code call system("cp /tmp/foo.txt /tmp/bar.txt") into a vim command which is more portable and OS-independent? I've been looking around but checking for "...
ColinKennedy's user avatar
4 votes
1 answer
3k views

Open files with "whitespace names" from within Vim with gx

I have a file, e.g. ~/abc def.mp3 that I want to open from within a Vim buffer that already contains these lines. If there were no whitespaces in the filename, I could simply open the file with the ...
cbaumhardt's user avatar
  • 2,139
3 votes
0 answers
1k views

What is the file structure of Neovim?

It seems like Neovim has files in many places. The binary is in /usr/bin/nvim. Inside ~/.config/nvim is init.vim, for declaring plugins, and also directories in ~/.config for storing Neovim plugins, ...
Julius Hamilton's user avatar
3 votes
0 answers
234 views

While copying a file in netrw, why should I be in the directory where the file is located?

In netrw, I want to copy a file /dir/subdir1/file.txt to /dir/subdir2. For that, I do the following: I mark the file /dir/subdir1/file.txt I navigate up directory and mark /dir/subdir2/ as target ...
E. Anikin's user avatar
  • 131
3 votes
0 answers
339 views

Netrw problem - 'mt' open new tab instead of marking as target folder

I was playing with netrw and was amazed by the possibility. I'd like to mark some files with 'mf' and move it to a folder using 'mt'. However, when I press 't', vim seems to interprets it as "open a ...
raoul59's user avatar
  • 31
3 votes
0 answers
705 views

How to escape paths for findfile() and finddir()?

I have run into an escaping problem with the path argument to findfile({name}, {path}) / finddir({name}, {path}). In my code path is a directory, obtained via fnamemodify(<file>, ':h'). Until ...
Andy Stewart's user avatar
  • 1,359
3 votes
1 answer
687 views

How to refresh the oldfiles list without restarting Vim?

:browse oldfiles<cr> is useful for quickly navigating to a file I've worked on recently. Sometimes though, I want to suspend vim and do some grep or ack search and find a new file that I'm ...
Greg Nisbet's user avatar
  • 1,849
2 votes
0 answers
61 views

Closing the file handle while keeping buffer open

I have a workflow where I edit a .org file using jceb/vim-orgmode which is located in my iCloud directory. I then have an app on my phone which also syncs and uses the same .org file. The problem is ...
Gérard Depardieu's user avatar
2 votes
0 answers
69 views

How long can a file be non-existent when I'm saving it in vim

When I'm using vim to edit files in a django application that is running in developer mode I sometimes encounter this crash coming from the auto-reload utility: File "/home/zefciu/.virtualenvs/15five/...
zefciu's user avatar
  • 121
2 votes
0 answers
78 views

Alter how oldfiles are displayed

Is it possible to "preprocess" the oldfiles list so that it's easier to navigate visually? As far as I can tell, the contents of the oldfiles list are presented as ordinary absolute paths, but with ...
Greg Nisbet's user avatar
  • 1,849
0 votes
1 answer
67 views

mkview file code meaning

I use :mkview %.vimview to create a view file under current directory, and in the file created there is a line of code like this: if bufexists(fnamemodify("~/PycharmProjects/rl/report/...
Yuanhao JIANG's user avatar
0 votes
1 answer
112 views

Is there a way to prevent Neovim from editing another file?

When I'm using Neovim in conjunction to firenvim to edit a text box in the browser, I typically have the need to open another file. I'd like to disable Neovim's ability to read from and write to other ...
ChocolateOverflow's user avatar