(tar.info)prepare for examples
Preparing a Practice Directory for Examples
To follow along with this and future examples, create a new directory
called `practice' containing files called `blues', `folk' and `jazz'.
The files can contain any information you like: ideally, they should
contain information which relates to their names, and be of different
lengths. Our examples assume that `practice' is a subdirectory of your
Now `cd' to the directory named `practice'; `practice' is now your
"working directory". (*Please note*: Although the full path name of
this directory is `/HOMEDIR/practice', in our examples we will refer to
this directory as `practice'; the HOMEDIR is presumed.
In general, you should check that the files to be archived exist
where you think they do (in the working directory) by running `ls'.
Because you just created the directory and the files and have changed to
that directory, you probably don't need to do that this time.
It is very important to make sure there isn't already a file in the
working directory with the archive name you intend to use (in this case,
`collection.tar'), or that you don't care about its contents. Whenever
you use `create', `tar' will erase the current contents of the file
named by `--file=ARCHIVE-NAME' (`-f ARCHIVE-NAME') if it exists. `tar'
will not tell you if you are about to overwrite a file unless you
specify an option which does this . To add files to an existing
archive, you need to use a different option, such as `--append' (`-r');
see Note: append for information on how to do this.
Next: Creating the archive Prev: create Up: create
[ Dokumentation lokal installierter Software ]