qvacua / vimr

VimR — Neovim GUI for macOS in Swift
https://twitter.com/VimRefined
MIT License
6.62k stars 218 forks source link

SUGGESTION: More Consistent Working Directory Behaviour #980

Open madranet opened 1 year ago

madranet commented 1 year ago

If I have a project consisting of a folder full of files, I can CTRL-click on that folder in Vimr's sidebar and select Set as Working Directory to make that folder the 'root' folder in the sidebar. However:

1: there's no option to control click on that folder in the sidebar [or any subfolder in the project] and Create New File Here 2: File > New opens a new bufffer with the sidebar back at the root of my computer [rather than the above selected working directory folder] 3: File > Save drops me at my ~/Documents folder 4: File > Open also drops me at my ~/Documents folder 5: However :w `pwd`/filename.txt does write any newly created file to the chosen working directory. Which will almost always be the desired location.

...and it could be argued that is the 'proper' [N]vim way to do it. But I think it would be more consistent if the GUI options also took account of the fact that the working directory has changed when we Set as Working Directory a folder in the sidebar . So File > Open/Save dialogues should open there instead of defaulting to ~/Documents. Likewise, it would be convenient to be able to CTRL+Click in the sidebar and choose New File/Folder Here as other editors allow [eg: TextMate, VSCodium]