Directory processing commands

Source: Internet
Author: User

Create directory: mkdir

mkdir-p [directory Name]

-P Recursive creation

Command English willing: make directories

Switch directory: CD

CD [catalogue]

Command English original: Change directory

Simplified operation:

CD: Enter the current user's home directory

CD target directory: Go to target directory

CD-: Go back to your last directory

CD ~: Enter the current user home directory

Cd. : Enter the current directory

Cd. .: Go to the top level directory

Check your directory location: pwd

Pwd

Command English original: Print working directory

Note: PWD is viewing an absolute path.

Absolute path: From the root directory, first-level recursive lookup. In any directory, you can enter the specified location.

such as: [[email protected]~] #cd/etc/

Relative path: Look for the current directory.

such as: [[email protected]~] #cd. /usr/local/src/

Delete Empty directory: RmDir

rmdir [directory Name]

Command English original meaning: remove empty directories

Delete files or directories: RM

RM-RF [file or directory]

-R: Delete Directory

-F: Force delete

Command English original meaning: remove

Copy command: CP

CP [Options] [Original file or directory] [target directory]

Command English Original: copy

Options:

-R Copy Directory

-P Joint File attribute copy

-D Wakahara file is a linked file, copy link properties

-A equals-DPR

Cut or rename command: MV

MV [original file or directory] [target directory]

Command English Intent: move

Note: The original file and the target target file are renamed in the same directory.


This article is from the "cloud" blog, be sure to keep this source http://walterliew.blog.51cto.com/11286797/1878670

Directory processing commands

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.