When I exit ROX-Session, I would like to have it clean up some processes
which don't terminate nicely.
I know I could add these to xinit or a startup script, but I wanted to
know how I could have a certain shutdown script run on exit. This would
only apply to the logout choice.
My thought is to have a Choices/Shutdown directory comparable to the
AutoStart one. Then, like Login does, have any and all scripts or
applications run on exit.
So, would it be feasible to have a Shutdown script in ROX-Session which
would do something like Login does except on exit:
# Run any other stuff the user wants by searching all the
# Choices/ROX-Session/Shutdown directories...
for DIR in $CHOICESPATH; do
if [ -n "$DIR" ]; then
for PROG in $AS/*; do
if [ -d "$PROG" ]; then
elif [ -x "$PROG" ]; then
This would be consistent with KDE and other WMs which can optionally run
Then the user could create a ~/Choices/Shutdown directory and
automatically have his/her scripts run.