Not a sandwich, but a Vim Which!
I often find myself going to find scripts I’ve written that I want to edit, but I decided today I’d make things easier on myself:
hank@rura-penthe ~ $ cat bin/vimwhich
#!/bin/bash
vim `which $1`
All this does is shorten vim `which myscript` to vimwhich myscript. Helpful for just a couple lines of code.


Tarmo
March 26, 2007 at 6:40 PM
If you used zsh (which does many things better than bash) you could just use: vim =scriptname
dayne
March 26, 2007 at 6:40 PM
or you can use bash alias (since bash rocks so much)
function vimwhich(){ vim `which $1`; };