Symlinking Emacs.app to the $PATH

Tim Visher tim.visher at gmail.com
Fri Nov 14 10:01:09 PST 2008


Thanks for the tip, vincent.  I implemented what you suggested and it
appears to work.

On Fri, Nov 14, 2008 at 9:14 AM, Vincent Lefevre
<vincent-opdarw at vinc17.org> wrote:
> On 2008-11-14 00:29:03 -0600, Ryan Schmidt wrote:
>> alias emacs='open -a "/Applications/MacPorts/Emacs.app"'
>
> This won't work with options. It's better to write a wrapper script.
> I use the following one:
>
> #!/bin/sh
>
> app="Emacs.app/Contents/MacOS/Emacs"
> #emacs="/Applications/$app"
> test -x "$emacs" || emacs="/Applications/MacPorts/$app"
> test -x "$emacs" || emacs="/usr/bin/emacs"
>
> exec "$emacs" ${SSH_CONNECTION:+-nw} ${SCREEN_IN_SSH:+-nw} "$@"
>
> This also allows Emacs to automatically run in the terminal (instead
> of the physical screen) when it is a ssh session (one can also do
> this for a screen session recalled from a ssh session, but this
> needs some config).
>
> --
> Vincent Lefèvre <vincent at vinc17.org> - Web: <http://www.vinc17.org/>
> 100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/>
> Work: CR INRIA - computer arithmetic / Arenaire project (LIP, ENS-Lyon)
> _______________________________________________
> macports-users mailing list
> macports-users at lists.macosforge.org
> http://lists.macosforge.org/mailman/listinfo.cgi/macports-users
>



-- 

In Christ,

Timmy V.

http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail


More information about the macports-users mailing list