[ubuntu-uk] Clearing home directory at logout

Alec Wright alecjw at gmail.com
Thu Jan 29 23:26:22 GMT 2009


Not sure about clearing it on logout, but i expect clearing it on login will
do? System>Prefs>Sessions
Add>Command: rm -fr $HOME/* ; cp /etc/skel/* $HOME/
That deletes everyhting in the come dir and then copies the default home dir

2009/1/29 Rob Beard <rob at esdelle.co.uk>

> Hi folks,
>
> I was wondering if anyone knew how to clear out the home directory on
> Ubuntu when a user logs out?
>
> Basically what I to achieve is have a script run to automatically when a
> user logs out of their Gnome session so it resets everything back to the
> default.  I've tried putting a couple of commands into .bash_logout to
> see it that works but it doesn't seem to run on a Gnome session logout.
> I just wondered if anyone knew how I could specify a script to run at
> logout for specific users?
>
> Ta,
>
> Rob
>
>
> --
> ubuntu-uk at lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/ubuntu-uk
> https://wiki.ubuntu.com/UKTeam/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.ubuntu.com/archives/ubuntu-uk/attachments/20090129/ddeeb42c/attachment.htm 


More information about the ubuntu-uk mailing list