Home>Article>Operation and Maintenance> What is the command to copy files to a specified directory in Linux?

What is the command to copy files to a specified directory in Linux?

王林
王林 Original
2020-06-01 11:15:51 20410browse

What is the command to copy files to a specified directory in Linux?

The command in Linux to copy files to a specified directory is the cp command.

"cp" is the abbreviation of copy. The syntax format of this command is:

cp filename 指定路径

For example, file1 is in directory A, and we want to copy file1 to directory B. The command is

cp file1 /home/B

This command includes three parts:

1, cp

2, the name of the file you want to copy

3, the path of the B directory

The following command is to copy file1 in directory A to directory B

What is the command to copy files to a specified directory in Linux?

Recommended tutorial:linux tutorial

The above is the detailed content of What is the command to copy files to a specified directory in Linux?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn