I'm trying to write a function that will accept a gem name and run Ctrl-P in the directory of that gem based on what Bundler shows. Right now I'm stuck on how to capture the output from the shell command.
So far I have:
function! GemCtrlP(gem_name)
execute '!bundle list ' . a:gem_name
endfunction
I want to save the output of the of that bundle call and then pipe that into CtrlP. I can do the CtrlP part, but I'm not sure how to capture the shell output
Any ideas?