How Do You Use the Copy Command in the Linux Terminal?

Published: 21 August 2021
on channel: Virtual Assistant for Linux
49
1

cp (Copy) is a command used for copying files and directories in Linux.

To copy a file with the cp command pass the name of the file to be copied and then the destination.

For example, by running the below-mentioned command will copy a file background.jpg to a Pictures/ directory.

cp background.jpeg Pictures/

If you want to copy the file under a different name, you need to specify the desired file name.

cp background.jpeg new-logo.jpeg

To copy multiple files, pass the names of files followed by the destination directory to the cp command.

cp new-logo.jpeg thisfile.txt ~/Documents/

To copy a directory, including all its files and subdirectories, use the -r (recursive) option.

For example, we are copying the directory Documents to Docs_bckp.

cp -r Documents/ Docs_bckp/



VAL utilises the following open source software.
GIMP for thumbnail.
Openshot for video editing.
Mimic for speech.
Kazam for screen recording.
Terminology for terminal emulator.
Featherpad for text editor.
Midnight Commander for managing files.
MX Linux operating system.


Watch video How Do You Use the Copy Command in the Linux Terminal? online, duration hours minute second in high quality that is uploaded to the channel Virtual Assistant for Linux 21 August 2021. Share the link to the video on social media so that your subscribers and friends will also watch this video. This video clip has been viewed 49 times and liked it 1 visitors.