Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: pre-populate path at the end of a : command line. #11

Open
fedemp opened this issue Sep 1, 2014 · 2 comments
Open

Comments

@fedemp
Copy link

fedemp commented Sep 1, 2014

Since filebeagle does not have a native implementation to delete files, it would be useful having something like https://github.com/tpope/vim-vinegar has.

Press . on a file to pre-populate it at the end of a : command line. This is great, for example, to quickly initiate a :grep of the file or directory under the cursor. There's also !, which starts the line off with a bang. Type !chmod +x and get :!chmod +x path/to/file.

I know filebeagle has :ClipPathName but this would be different, cause the global register should not be used and the command line is prepopulated.

@spiderpug
Copy link

In case you could live with the register solution:

I'm using this at the moment and I'm happy with it.

autocmd User FileBeagleReadPost nnoremap <buffer> . :ClipPathname<CR>:<C-U> <C-R>+<Home>
autocmd User FileBeagleReadPost nnoremap <buffer> ! :ClipPathname<CR>:<C-U> <C-R>+<Home>!

It would still be great if there was a solution without using the clipboard.

@nicwest
Copy link
Contributor

nicwest commented Oct 13, 2015

@spiderpug have you tried :PreFill? I see that I forgot to add it to the docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants