Script for friendlier home partition under other OS
Christoph Georgi
christoph.georgi at web.de
Tue Jun 7 00:12:35 UTC 2005
I suppose the . is interpreted not as character. Try '\.'
hth
christoph
Gábor Iglói wrote:
> Hello!
>
> I'm trying to solve the following problem with an init/shutdown script:
>
> If one is holding his/her home on a different partition from / and
> using a dual-boot system it is a bit confusing that the hidden
> .folders and .files are all visible under another OSs.
>
> I'd like to solve the problem with a pair of scripts: on Ubuntu bootup
> it would untar all hidden folders/files of the user's home folder from
> a tar file somewhere in the filesystem. And during shutdown another
> script would tar all of the user's hidden home folders and files - but
> just these. With a bootup check for the existence of the tar file I
> could avoid situations when the user exited Linux foolishly thus
> missing the creation of the tar file (e.g. after pressing the Reset
> button by accident).
>
> Problem is that I didn't manage to find out the correct syntax for
> tarring ONLY the hidden files/folders. I tried the following:
>
> cd /home/user
> tar -cvzf /someplace/home.tgz .*
>
> This will tar the whole home folder hidden an normal files too.
>
> tar -cvzf /someplace/home.tgz --exclude=./* .*
>
> This does the same - don't understand why.
>
--
Christoph Georgi
-----------------------------
email. christoph.georgi at web.de
fon. +64 (0)9 815 8259
registered linux user #380268
ubuntu 5.04 (ubuntu.com)
More information about the ubuntu-users
mailing list