[Xquartz-dev] 2.3.2_rc4
Martin Costabel
costabel at wanadoo.fr
Tue Dec 23 01:23:39 PST 2008
Cameron Simpson wrote:
[]
> Meanwhile, here's a beefier single-script solution that:
> - handles arbitrary paths
> - runs only the user's login stuff and nothing extra
> - passes the subcommand, bash-quoted, through the envionment to itself for
> re-execing in bash i.e. in the same shell dialect
> I need to do some more testing on it, but I think the approach is
> pretty robust.
>
> Here's the link:
> http://www.cskk.ezoshosting.com/cs/css/bin/with-login-env
> Usage:
> with-login-env some-command [args...]
This doesn't work with bash. If run with the --have-login-env flag, it says
./with-login-env: line 27: _WITH_LOGIN_ENV_QUOTED_COMMAND: unbound variable
If run without the flag, it does not load the bash startup scripts.
As I repeatedly said, bash does *not* load its startup scripts if run
after "exec -l" or after /usr/bin/login. It is correctly executed with
the name "-bash", but it does not start up as a login shell. Whether
this is a bug in Apple's version of bash, I don't know, but this is how
it behaves. You have to use "bash --login" to have it read its startup
scripts.
Harald's "untested" script does not work as X11 wrapper script: It does
not execute X11.bin.
--
Martin
More information about the Xquartz-dev
mailing list