Thank you Tim. That worked.
On Oct 23, 12:05 pm, Tim Chase <[EMAIL PROTECTED]> wrote:
> > I'd like to insert the path of the file I'm currently editing into the
> > active buffer. Is there any way to do that short of writing a function?
>
> you can use "expand('%:p:h')" (which can be done with control+R
> followed by "=" to pull in the expression register). Thus, the
> whole thing might be wrapped up in a mapping as
>
> :inoremap <f4> <c-r>=expand('%:p:h')<cr>
>
> You can learn more at
>
> :help expand()
> :help filename-modifiers
> :help i_CTRL-R
>
> Hope this helps,
>
> -tim
--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---