I don't know whether this is of any interest at all, but just in case: CrunchBang Linux has a script called cb-lock for running xscreensaver.

These are the contents (from my installation, CrunchBang Statler (Alpha 2):


#!/bin/bash
# cb-lock
# -------
# This is a wrapper for the 'xscreensaver-command -lock' command.
# If running in live mode, offer up a prompt detailing the live session password.
# Else, run xscreensaver-command -lock.
# Simples!
if [ -d /live/cow ]; then
    if [ ! -f /home/$USER/.config/crunchbang/cb-lock ]; then
        zenity --info --title="Lock screen info:" --text="Lock screen has detected you are running a live session.\nThe password needed to unlock the screen is \"live\".\nThis notice will only be displayed once per live session."
        if [ ! -d /home/$USER/.config/crunchbang ]; then
            mkdir /home/$USER/.config/crunchbang
        fi
        touch /home/$USER/.config/crunchbang/cb-lock
        xscreensaver-command -lock
        exit 0
    fi
    xscreensaver-command -lock
else
    xscreensaver-command -lock
fi
exit 0


--
Chris Watkins

Appropedia.org - Sharing knowledge to build rich, sustainable lives.

blogs.appropedia.org
community.livejournal.com/appropedia
identi.ca/appropedia
twitter.com/appropedia