This blog contains some important fundae for linux users, which may look very trivial, but are very useful.

tar: append files to an archive

To demonstrate using `--append' to add a file to an archive, create a file called `rock' in the `practice' directory. Make sure you are in the `practice' directory. Then, run the following tar command to add `rock' to `collection.tar':

$ tar --append --file=collection.tar rock 

If you now use the --list (-t) operation, you will see that `rock' has been added to the archive:

$ tar --list --file=collection.tar
-rw-rw-rw- me user 28 1996-10-18 16:31 jazz
-rw-rw-rw- me user 21 1996-09-23 16:44 blues
-rw-rw-rw- me user 20 1996-09-23 16:44 folk
-rw-rw-rw- me user 20 1996-09-23 16:44 rock

0 comments: