How to configure the bash file?
I use:
alias cemacs='open -a /Applications/Emacs.app'
Then I can type cemacs foo.txt and have emacs open the file.
cemacs foo.txt
(Is that what you were asking? The question was a little vague.)