Blame | Last modification | View Log | Download | RSS feed
#!/bin/bash## autostart is execute at login# (executed by .xinitrc)#### source liblinuxliveMOUNTDIR=livecd. /$MOUNTDIR/live/liblinuxlive### get run=... from kernel parameterRUN=$( cmdline_value run )### run not defined -> exitif [ ! $RUN ]; thenif [ -x /usr/bin/psi-menu ]; then/usr/bin/psi-menu &elsexterm -geometry 100x30+100+100 &fifi### functionspoweroff_system(){Xdialog --yesno '\nShutdown your PC now ?\n' 0 0if [ "$?" = "0" ]; thenpoweroffsleep 20fi}### rdesktop, afterwards ask to poweroffif [ "$RUN" = "rdesktop" ]; thenwhile [ "" = "" ]; dordesktop $RDESKTOP_OPT -d PSICH -f -u win_username -a24 -x lan -r sound:local winterm1poweroff_systemdonefi### nx client, afterwards aks to poweroffif [ "$RUN" = "nxclient" ]; thenwhile [ "" = "" ]; donxclientNXDOWN=""while [ ! $NXDOWN ]; dosleep 1ps wwaux | grep -v grep | grep -q nxssh[ "$?" = "1" ] && NXDOWN=yesdonekillall nxclientpoweroff_systemdonefi### start what is given by "run"$RUN &