Copying files is a very common task in UN*X, basic usage is:
cp file1 file2 E.g. cp oldfile newfile
Multiple files can also be copied with this command. In this case the destination must be a directory.
cp file1 file2 newdirectory
This example will copy two files named "file1" and "file2" to a directory called "newdirectory".
The "-r" (recursive) flag can be used to copy complete directories as in this example:
cp -r dir1 newdir
where the directory "dir1" with all of its contents (files and subdirectories) will be copied to the directory "newdir".
a production of
Cadence is a trademark of Cadence Design Systems, Inc., 555 River Oaks Parkway, San Jose, CA 95134.
Please read this DISCLAIMER