Vim: Copy Current Buffer’s Full Path and Filename to Clipboard
:!echo % | pbcopy
I use this all the time, so it's mapped to a key.
Written by James Martin
Related protips
1 Response

autocmd BufDelete * let g:latestdeletedbuffer = expand("<afile>:p")
nnoremap <F8> :e <C-R>=fnameescape(g:latestdeletedbuffer)<CR><CR>
over 1 year ago
·
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Vim
Authors
Related Tags
#vim
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#