A.J.Mechelynck wrote:
In the vim Explorer (:Explore), I can create a new directory by pressing 'd' and typing the directoryname. Is there something similar for creating a new, empty file? I've looked through the documentation
    :map    <F2>    :cd %:p:h <Bar> new<Space>
will allow you to open a new file in the currently browsed directory, or, if currently not browsing a directory, in the same directory as the current file. (Replace <F2> by any other shortcut key you want to use.) The cursor ends up on the command line, ready for you to enter the filename. Hit <Enter> without a filename to open a [No Name] buffer; hit <Esc> to cancel.


This is great, thanks. Is there also a way to make this work only in the Explorer window/mode?


cheers,

roel

Reply via email to