xrt 1.01 (C) Richard K. Lloyd 1993 What is xrt ? ------------- xrt (short for "xroottext", but that had too many t's in it !) allows you to write a box containing text directly onto the root window, with an optional title line. What use is it ? ---------------- It's always been immensely frustrating in our department that users couldn't read /etc/motd until they logged in. For example, take a message such as: All Undergraduate users' passwords have been changed. These users should now re-register and obtain a new password. This cannot be read until the user logs in, but their password has been changed, so they can't log in. Chicken and egg situation ! This is where xrt comes in - if you are running an xdm login front-end, it is possible to allow a program (usually a shell script) to be run prior to presenting the xdm login panel. Any programs run in that script would normally have to be backgrounded (unless they ran very quickly) and - importantly - AREN'T killed when the user types their username and password and logs in. So, usually just about the only thing that can be run sensibly in that script is something to change the background and I bet that's what most sites usually do (e.g. a Departmental logo in the background or a pretty picture). However, what if you want to display a message (which may or may not be available and which will change from time to time) ? Running something like xless is no good because you can't kill it after the user logs in (um, I suspect you could by saving its PID, but it's very messy indeed) and what's to stop a user from quitting xless and leaving no motd message up for the next poor soul who wants to log in at that terminal ? To cut a long story short... ---------------------------- So that's why I set about writing xrt - something that would write text in a box directly to the root window and then exit immediately. A simple xsetroot once the user has logged in clears the message. By adding various command-line flags, I've tried to cater for the possible things a systems admin person might to change w.r.t. the appearance of the text/box (um, except colour - that was tricky and may be done in the future). Read the man page for further info, Changes between versions are documented in the CHANGES file naturally enough. You may find it useful to know that our motd's are displayed using: xrt -c -d -f timr18 -h -p 80 -t "Message Of The Day" /etc/motd /usr/local/etc/xmotd To compile and install ---------------------- The only configuration that should be required is the time zone setting (for the -d time/date option) and whether you want to fall back on a default time zone if the environmental variable TZ *isn't* set. Remember that's it's quite likely that TZ *isn't* set during the xdm login screen, which is the first place you'll probably want to run xrt. Either change the #define TIMEZONE in the Imakefile appropriately or even comment it out if you don't want a fallback time zone. Just type: [Edit Imakefile for your site] xmkmf make install install.man Tested on --------- HP 9000/720 running HP-UX 9.01 and X11R5. Sun 4 running SunOS 4.1.3 and X11R4. Credits ------- Author of xroach, J.T. Anderson , for his FindRootWindow() routine. Rik Turnbull for colour coding suggestions. Report bugs to -------------- Richard K. Lloyd