tar up a symbolic linked directory
Hi,
I want to tar up a symbolic linked directory as if it is a real
directory. Is there any easy way to do it?
Let me explain with an example (that you can try):
mkdir d1
touch d1/{a,b,c}
ln -s c d1/d
ln -s d1 d2
I want that the result tar file looks like this:
tar -tvzf d2.tgz
drwxrwx--x tong/tong 0 2009-05-01 09:38 d2/
-rw-rw---- tong/tong 0 2009-05-01 09:37 d2/a
-rw-rw---- tong/tong 0 2009-05-01 09:37 d2/b
-rw-rw---- tong/tong 0 2009-05-01 09:37 d2/c
lrwxrwxrwx tong/tong 0 2009-05-01 09:38 d2/d -> c
Any easy way to do it?
Thanks
--
Tong (remove underscore(s) to reply)
http://xpt.sourceforge.net/techdocs/
http://xpt.sourceforge.net/tools/
Reply to: