Webmonkey
Powered by Atomz.com



Quick Reference:

Javascript Code Library
HTML Cheatsheet
Special Characters
Color Codes
Browser Chart
Stylesheet Guide
• Unix Guide
Glossary
Domain Registries

Reference   Unix Guide

cp

The cp command copies files or directories from one place to another. You can copy a set of files to another file, or copy one or more files under the same name in a directory. If the destination of the file you want to copy is an existing file, then the existing file is overwritten. If the destination is an existing directory, then the file is copied into that directory.

Structure: cp [options] file1 file2
cp [options] files directory

If you wanted to copy the file gorilla.html into the directory called apes, here's what you would do:

 cp gorilla.html /webmonkey/apes/

A handy option to use with cp is -r. This recursively copies a particular directory and all of its contents to the specified directory, so you won't have to copy one file at a time.

Back to the index.



Feedback  |  Help  |  About Us  |  Contribute  |  Jobs
Advertise  |  Privacy Statement  |  Terms and Conditions

Copyright © 1994-2000 Wired Digital Inc., a Lycos Network site. All rights reserved.