I have a very simple function
function filefinder
{
FILE=$1; test -f $FILE || FILE=`find . -name $FILE`; /usr/bin/geany $FILE
}
alias geany=filefinder
But I would like other editors to use the same function. How can I do that? Say, I would like to add alias nano=filefinder. Obviously I wouldn’t like to hardwire either geany or nano.
How about:
I assumed your distro keeps all the execs in /usr/bin