Vim: Creating parent directories on save

前端 未结 6 1810
一生所求
一生所求 2020-12-07 08:32

If I invoke vim foo/bar/somefile but foo/bar don\'t already exist, Vim refuses to save.

I know I could switch to a shell or do :!mkdi

6条回答
  •  北海茫月
    2020-12-07 09:20

    I made :saveas! create the directory if missing: https://github.com/henrik/dotfiles/commit/54cc9474b345332cf54cf25b51ddb8a9bd00a0bb

提交回复
热议问题