From: Nicholas Clark Date: 14:22 on 25 Aug 2006 Subject: Xquartz Something isn't honouring my profile... My profile sets HISTSIZE to something non-default so that more bash history gets saved. Login shells are happy. Children spawned from login shells are happy - they inherit the environment, as it should be. It turns out to be the OS X X server. Its default is to spawn an xterm. It's doing this from a clean environment (ie it's not run my profile) but it doesn't run the xterm with -ls to make it a login shell. So nothing is running my profile. Mmm. I don't have an .xsession here, I don't really feel like creating one just for this, so as it's "my" laptop I investigate what the system default is. It seems to be /private/etc/X11/xdm/Xsession And lo, that file has a bare unadorned "xterm". So I change it to "xterm -ls". Does this work? Hell no. The bastard X server isn't using that, and is (or at least as far as all the documentation and preferences goes) hard coded to start xterm. And fuck my shell history over. Hate. Nicholas Clark
From: Ole-Morten Duesund Date: 14:58 on 25 Aug 2006 Subject: Re: Xquartz On 25. aug. 2006, at 15:22, Nicholas Clark wrote: > Something isn't honouring my profile... > > My profile sets HISTSIZE to something non-default so that more bash > history > gets saved. Login shells are happy. Children spawned from login shells > are > happy - they inherit the environment, as it should be. > > It turns out to be the OS X X server. Its default is to spawn an xterm. > It's doing this from a clean environment (ie it's not run my profile) > but > it doesn't run the xterm with -ls to make it a login shell. So nothing > is > running my profile. > > Mmm. I don't have an .xsession here, I don't really feel like creating > one > just for this, so as it's "my" laptop I investigate what the system > default > is. It seems to be /private/etc/X11/xdm/Xsession > And lo, that file has a bare unadorned "xterm". > So I change it to "xterm -ls". > Does this work? > > Hell no. > > The bastard X server isn't using that, and is (or at least as far as > all > the documentation and preferences goes) hard coded to start xterm. Not excusing the X server. It deserves a lot of hate, but this time it is actually not at fault. Unless you're doing something fairly unusual on your mac, you're not running xdm, so /private/etc/X11/xdm/Xsession has nothing to do with your x-session. /private/etc/X11/xinit/xinitrc (or ~/.xinitrc) on the other hand does. Fix either one to get back to hating bash, HISTSIZE or whatever. Not to mention xterm. Ole-Morten Duesund
From: Chris Devers Date: 20:16 on 25 Aug 2006 Subject: Re: Xquartz On Fri, 25 Aug 2006, Nicholas Clark wrote: > The bastard X server isn't using that, and is (or at least as far as > all the documentation and preferences goes) hard coded to start xterm. On Tiger, you should be able to prove or disprove this with `fs_usage`: * launch Terminal * `sudo fs_usage | grep -i x11` (tweak the grep filter as needed) * launch X11 * thousands of filesystem accesses flow by in Terminal window * find the one that mentions how xterm, possibly by doing e.g.: * repeat steps with `sudo fs_usage | grep -i x11 | grep -i xterm` * repeat steps with `sudo fs_usage | grep -i '/usr/X11' (etc) * repeat steps with `sudo fs_usage | grep -i 'X11.app' (etc) * use cmd+f to search the terminal window's buffer Etc.
From: peter (Peter da Silva) Date: 22:58 on 25 Aug 2006 Subject: Re: Xquartz > The bastard X server isn't using that, and is (or at least as far as all > the documentation and preferences goes) hard coded to start xterm. It starts whatever the CMD-N item is on the "File" menu, which is normal for OS X applications. Sorta. Unless they're by Microsoft or Adobe or even Apple now and start a whiny wizard... [insert hate here] I don't know whether I like this or not, because I have a long-running love-(turned-to-hate)-hate relationship with the various X11 session startup files from boring-but-rational old .xinitrc through the preversions that CDE foisted upon us. Add to that the various other ways that a shell can get started without it being a login shell or inheriting a sane environment... [I'd go on, but it's an old, dry hate, hadly worth the effort] I gave up on .login long since, and have a .cshrc that starts something like if ( ! $?LOGINSHELL ) then setenv LOGINSHELL $$ # .. proceed with "this is my first shell, act like a login shell" stuff if ( $?prompt ) then tset -e -k # ... etc endif set path=($path ~/bin /usr/local/bin /sw/bin /opt/local/bin) # ... etc endif I'm sure something similar could be arranged for folks who prefer [kb]ou?rne? (again)? shells.
Generated at 10:26 on 16 Apr 2008 by mariachi