aboutsummaryrefslogtreecommitdiff
path: root/doc/write_mkpath.txt
blob: 33aec4d87392177eee99b15ef02aede3e9b7fede (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
*write_mkpath.txt*	For Vim version 7.2	Last change: 2019 Jun 01

DESCRIPTION				*write_mkpath*

This plugin supports creation of any missing path elements in the path to a
buffer's filename before the buffer is written.

If 'confirm' is enabled on |:write| or |:w|, the user will be prompted to
confirm that Vim should create any missing path elements.

On |:write!| or |:w!|, the path will be created automatically, ignoring the
value of 'confirm'.

The directory creation is done using the |mkdir()| command, with its {path}
argument set to 'p' to create the elements recursively.

REQUIREMENTS				*write_mkpath-requirements*

This plugin only loads if 'compatible' is not set.

CAVEATS					*write_mkpath-caveats*

The path will be created relative to Vim's working directory at the time of
the write operation, which might not be the same as the working directory when
the buffer was first created, e.g. after a |:cd| change.

AUTHOR					*write_mkpath-author*

Written and maintained by Tom Ryder <tom@sanctum.geek.nz>.  Inspired by Damian
Conway's `automkdir.vim` plugin:
<https://github.com/thoughtstream/Damian-Conway-s-Vim-Setup/blob/cbe1fb5/plugin/automkdir.vim>

LICENSE					*write_mkpath-license*

Licensed for distribution under the same terms as Vim itself (see |license|).

 vim:tw=78:ts=8:ft=help:norl: