What I'd like to do to ensure that users get a uniform and 'non-broken' desktop environment when they log in is to copy enough stuff into their home directory at login to ensure their desktop, menus, panel etc are what we would like them to be. Sadly, this seems to be a little more complicated than just copying in a set of files from a 'golden' user's home directory as many of the config files (e.g. konquerors file management profile) have hard wired paths to the 'golden' user's home directory. Another problem we have is that You could try setting up a template user with "~" subsituted for the user. This will work some of the time. Alternativily you can generate the files fron a shell script using environment variables such as $USER, which works well with the preferences.js file in the older versions of Netscape. (Which needs variations on the username and home directory in multiple places.) The newer versions of Netscape appear to use ~/.mozilla/$USER/$OUTPUT_OF_SOME_HASH_FUNCTION to store their config data (Galeon manages with ~/.galeon/mozilla/galeon even if we copy across the OpenOffice directory from a user who has already run through the open office network workstation installation, the first time the new user runs an open office component, they have to go through the setup process. Star/Open office is a big pain. Even with ~/<version>/user/sofficerc set up to contain the correct user details things you still get this. I think Michael Brown may know a solution.
You're right : we have had to solve this problem already. We have a (rpm) package available for StarOffice 5.2 that wraps StarOffice in order to create a default user working environment the first time a user tries to run StarOffice. The user will see the message "Initialising the StarOffice components for the first time after installation" but will not see any setup screens. This package also creates K menu entries for StarWriter, StarCalc etc. so that you can open up blank documents without going via the StarOffice desktop. It sets up MIME types so that StarOffice docs can be easily opened via Konqueror. It also hacks the StarOffice printing system so that you don't ever need to run spadmin. Probably the easiest way for me to distribute this is to publish the .nosrc.rpm that is used to generate the staroffice rpm. This is now available from http://osie.sourceforge.net/staroffice-5.2-6fs.nosrc.rpm. You will need to obtain the StarOffice installer binary (so-5_2-ga-bin-linux-en.bin) separately and place it in the SOURCES directory within your RPM build tree. If you don't know what this means, visit www.rpm.org and learn how to build RPMs from source. Running "rpm --rebuild staroffice-5.2-6fs.nosrc.rpm" should start the build process. It will run through the StarOffice graphical installer. Accept the path selected (/home/.../usr/share/staroffice). Once the process is complete, you will have a staroffice-5.2-6fs.i586.rpm file that you can install just as you would any other RPM. So far, there has been no need to do this for OpenOffice; the Mandrake package for OpenOffice installs an office suite that is already usable out-of-the-box, without requiring any setup process. (There is one minor irritation; it will ask where to find the user's address book, but I expect this to be a minor workaround). As far as the template KDE config files goes, try this: #!/bin/sh # Exit if user's .kde directory already exists [ -d ~/.kde ] && exit # Sample user to use as a template # Ensure that ~$SAMPLE_USER is world-readable SAMPLE_USER=sample_user # Calculate SAMPLE_USER's home directory SAMPLE_HOME=`eval echo ~$SAMPLE_USER` # Copy .kde from SAMPLE_HOME to ~ cp -dR $SAMPLE_HOME/.kde ~/.kde # Search and replace instances of home directory for file in `find .kde`; do perl -pi -e "s{$SAMPLE_HOME}{$HOME}g" $file done Untested, use at your own risk etc. etc. This may not work if your distribution already does some hacking around with your .kde folder at KDE startup. I'm fairly sure it would fail under Mandrake, for example. As far as a proper, elegant solution goes: I don't yet know of one although I'm working on it. Michael