Skip to content

Instantly share code, notes, and snippets.

@bittersweet
Created May 30, 2011 14:19
Show Gist options
  • Save bittersweet/998960 to your computer and use it in GitHub Desktop.
Save bittersweet/998960 to your computer and use it in GitHub Desktop.
how to insert current file with vimscript
function! InsertCurrentFile()
let filename = expand("%:p")
execute "normal a".filename
endfunction
:call InsertCurrentFile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment