From owner-freebsd-questions@FreeBSD.ORG Sat Mar 6 06:38:50 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C56531065670 for ; Sat, 6 Mar 2010 06:38:50 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mx02.qsc.de (mx02.qsc.de [213.148.130.14]) by mx1.freebsd.org (Postfix) with ESMTP id 81F8D8FC1E for ; Sat, 6 Mar 2010 06:38:50 +0000 (UTC) Received: from r55.edvax.de (port-92-195-7-176.dynamic.qsc.de [92.195.7.176]) by mx02.qsc.de (Postfix) with ESMTP id C2EDC1E65C; Sat, 6 Mar 2010 07:38:48 +0100 (CET) Received: from r55.edvax.de (localhost [127.0.0.1]) by r55.edvax.de (8.14.2/8.14.2) with SMTP id o266clHf002644; Sat, 6 Mar 2010 07:38:48 +0100 (CET) (envelope-from freebsd@edvax.de) Date: Sat, 6 Mar 2010 07:38:47 +0100 From: Polytropon To: Programmer In Training Message-Id: <20100306073847.54a0daef.freebsd@edvax.de> In-Reply-To: <4B91F1F0.5020605@joseph-a-nagy-jr.us> References: <20100305002520.c06d7d20.freebsd@edvax.de> <4B9048F9.1060907@joseph-a-nagy-jr.us> <20100305144625.GA43010@orange.esperance-linux.co.uk> <4B91F1F0.5020605@joseph-a-nagy-jr.us> Organization: EDVAX X-Mailer: Sylpheed 2.4.7 (GTK+ 2.12.1; i386-portbld-freebsd7.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: xorg, xdm, desktop env X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Polytropon List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 06 Mar 2010 06:38:50 -0000 On Sat, 06 Mar 2010 00:10:56 -0600, Programmer In Training wrote: > On 03/05/10 08:46, Frank Shute wrote: > > > If you read the manpage for xdm(1) you will see that the script that > > is run on login is ~/.xsession > > > > Try putting "exec wmaker" in there. > > > > To run xdm from boot, you have to edit /etc/ttys and then: > > > > # kill -HUP 1 > > > > Look at this: > > > > http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/x-xdm.html > > > > > > Regards, > > > > Thank you kind sir. A small addition: In order to be able to use X with an initialisation file even when not using XDM (i. e. starting X by "startx") AND not having to maintain two startup files (.xsession and .xinitrc) AND furthermore incorporating shell settings for the shell of choice (default: the C shell), you can use this approach: ~/.xsession #!/bin/csh source ~/.cshrc exec ~/.xinitrc It incorporates the shell settings and then continues running as .xinitrc - so xdm can pick this up. If you run "startx", .xsession isn't used, but .xinitrc is used. So this script contains what you want to automate, e. g. ~/.xinitrc #!/bin/sh [ -f ~/.xmodmaprc ] && xmodmap ~/.xmodmaprc xrandr --fb 1400x1050 xrandr --size 1400x1050 xsetroot -solid rgb:3b/4c/7a xset b 100 1000 15 & xset r rate 250 30 & xset s off & xset -dpms & exec wmaker The "#!/bin/sh" at the beginning isn't needed, according to the documentation. > Now to figure out how to set the ~/.xsession file up > automatically upon account creation (not an issue now, but might be later). You can use /usr/share/skel for the templates, it will be used by the adduser program. Create "dot.xsession" in this directory and modify it according to your default settings. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...