diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2019-05-31 22:47:24 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2019-05-31 23:03:10 +1200 |
commit | 837c3d975f232c5fddd00dac3def26efc4ab8609 (patch) | |
tree | fac124b435cad681204bca11fb25d83e51afd2b1 /autoload/write_mkpath.vim | |
parent | Handle :cd then buffer write of non-existent path (diff) | |
download | vim-write-mkpath-837c3d975f232c5fddd00dac3def26efc4ab8609.tar.gz vim-write-mkpath-837c3d975f232c5fddd00dac3def26efc4ab8609.zip |
Suppress potentially confusing :file output
Diffstat (limited to 'autoload/write_mkpath.vim')
-rw-r--r-- | autoload/write_mkpath.vim | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/autoload/write_mkpath.vim b/autoload/write_mkpath.vim index aca49f1..bfe45bd 100644 --- a/autoload/write_mkpath.vim +++ b/autoload/write_mkpath.vim @@ -17,8 +17,9 @@ function! write_mkpath#New(path) abort return endif - " Set filename to absolute path using :file {name} - execute 'file '.fnameescape(getcwd().'/'.a:path) + " Set filename to absolute path using :file {name}; do it silently so that + " the nice name remains displayed to the user + execute 'silent file '.fnameescape(getcwd().'/'.a:path) endfunction |