Advertisement
Guest User

Untitled

a guest
Jul 2nd, 2015
203
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. vim src/submodule/frontend/frobnicate2.c
  2.  
  3. In Ex commands, at places where a file name can be used, the following
  4. characters have a special meaning. These can also be used in the expression
  5. function `expand()`.
  6.  
  7. % Is replaced with the current file name. :_% c_%
  8.  
  9. :edit %.orig
  10.  
  11. :edit file/in/a/deeply/nested/subdirectory/here.txt
  12. :edit %:h/in_same_dir_as_above.txt
  13.  
  14. :edit %:h:h:h/file.txt
  15.  
  16. set path=./**
  17.  
  18. cnoremap <a-q> <c-c>:let @a=expand('%')<CR>:<Up><c-r>a
  19.  
  20. expand('%:p')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement