[Xquartz-dev] X11 startup script (was Re: 2.3.2_rc4)

Jeremy Huddleston jeremyhu at berkeley.edu
Mon Dec 29 21:23:14 PST 2008


I decided to go the more conservative approach in 2.3.2_rc5 and didn't  
use the "generic approach" ... I think I'll move that into  
2.4.0_alpha1 after 2.3.2 is released... I just want to let it get more  
testing first.

--Jeremy

On Dec 26, 2008, at 17:47, Cameron Simpson wrote:

> On 26Dec2008 15:21, Jeremy Huddleston <jeremyhu at apple.com> wrote:
>>> In fact, I've copied the whole case statement into my generic  
>>> script,
>>> which makes it more efficient in standalone use and lets you strip
>>> this
>>> wrapper down further, should you wish. It would let the wrapper be  
>>> an
>>> "if" statement, clearer in its purpose.
>>
>> Can you send your updated script to the list.
>
> Attached. It reduces the wrapper to:
>
>  #!/bin/sh
>  set "$(dirname "$0")"/X11.bin "${@}"
>                                                                                  if 
>  [ -x "$HOME/.x11run" ]; then
>    exec "$HOME/.x11run" "${@}"
>  else
>    exec with-login-env "${@}"
>  fi
>
>>> A minor question: why "${@}" instead of "$@" ? And why "${SHELL}"
>>> instead of "$SHELL"?
>>
>> Because things like $PREFIX/bin make me cry, so I like ${...}
>
> Ok.
>
>>> And we should put a usage message and abort at the top if there  
>>> are no
>>> arguments i.e. no command supplied:
>>
>> No... If there are no command line arguments, then we just exec  
>> X11.bin
>> with no command line arguments.
>
> Ah, I had missed this. Fine. Latest with-login-env attached. Cheers,
> --
> Cameron Simpson <cs at zip.com.au> DoD#743
> http://www.cskk.ezoshosting.com/cs/
> <with-login-env.txt>_______________________________________________
> Xquartz-dev mailing list
> Xquartz-dev at lists.macosforge.org
> http://lists.macosforge.org/mailman/listinfo.cgi/xquartz-dev



More information about the Xquartz-dev mailing list