Cp

From Linuxintro
Revision as of 06:46, 19 April 2014 by imported>ThorstenStaerk
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

The command cp is used to copy files. The following options are described here:

copy a file preserving its attributes

See cp -pr

copy all *.txt file to *.txt.bak

Most Linux distros use the bash shell, here the command is:

for i in *.txt; do cp $i $i.bak; done

See also