Tar/Zip/Rar trouble
Ben Stringer
ben at burbong.com
Fri Apr 30 08:16:06 UTC 2004
On Fri, 2004-04-30 at 16:53, J.L. Coenders wrote:
> Hi all,
> Does anyone know what how to hidden and backup files into an archive with
> tar/zip/rar?
> I want to backup my ~/Mail directory, but somehow it doesn't work with
> Fileroller so I want to try it manually (errors). However, I cannot find how
What are the errors?
> to pack hidden files. Maybe I am looking for the wrong thing or does anyone
> have another solution to my problem.
> And how can I test an archive to see if it works proper?
With "dot" files, you can either let tar's recursion pick them up by
tarring from the parent directory, or by specifying a regex that matches
them (like .??*).
Here is an example of the former case. The "tar tzf" is showing you the
contents of the compressed tarfile. Take out all the "z"'s if you don;t
want compression.
$ mkdir tartest
$ cd tartest
$ echo "Hello" > .hidden
$ echo "Goodbye" > not_hidden
$ cd ..
$ tar czvf mytar.tgz tartest
...
$ tar tzf mytar.tgz
tartest/
tartest/.hidden
tartest/not_hidden
Cheers, Ben
>
> Thanks,
> Jeroen
>
More information about the fedora-list
mailing list