Command immediate (cmd) is a robust instrument that lets you work together together with your pc’s working system. One of the frequent duties that you could be must carry out in cmd is to navigate via the listing construction of your pc. This may be carried out utilizing the “cd” command. Nevertheless, if it is advisable return to the earlier listing, you need to use the “cd..” command. On this article, we’ll present you the way to return listing in cmd utilizing the “cd..” command.
The “cd..” command is a shortcut for the “cd ..” command. The “cd” command is used to vary the present listing. The “..” represents the guardian listing of the present listing. Due to this fact, the “cd..” command will change the present listing to the guardian listing. For instance, in case you are at the moment within the “C:UsersYourUsernameDesktop” listing, and also you wish to return to the “C:UsersYourUsername” listing, you need to use the next command:
“`
cd..
“`
It will change the present listing to the “C:UsersYourUsername” listing. You need to use the “cd..” command to return to the guardian listing of any listing. This is usually a helpful shortcut when it is advisable navigate via the listing construction of your pc rapidly and simply.
Navigate the File System
Navigating the file system is an important ability for utilizing the command immediate. The next are some fundamental instructions for navigating the file system:
Present Listing
The present listing is the listing that’s at the moment being displayed within the command immediate window. To get the present listing, use the “cd” command with none arguments. For instance:
“`
C:UsersUser> cd
C:UsersUserDocuments
“`
Altering Directories
To alter the present listing, use the “cd” command adopted by the trail to the brand new listing. For instance, to vary to the “Downloads” listing, you’d use the next command:
“`
C:UsersUserDocuments> cd Downloads
“`
Itemizing Recordsdata and Directories
To checklist the recordsdata and directories within the present listing, use the “dir” command. For instance:
“`
C:UsersUserDownloads> dir
Quantity in drive C is OSDisk
Quantity Serial Quantity: 40ED-1E3A
Listing of C:UsersUserDownloads
02/20/2023 02:47 PM
02/20/2023 02:47 PM
02/20/2023 02:47 PM 1,922 setup.exe
02/20/2023 02:47 PM 110,852 software_installer.exe
02/20/2023 02:47 PM 4,608 test1.txt
02/20/2023 02:47 PM 4,608 test2.txt
5 File(s) 121,988 bytes
2 Dir(s) 102,170,649,600 bytes free
“`
Shifting Up a Listing
To maneuver up one listing, use the “cd ..” command. For instance, to maneuver from the “Downloads” listing to the “Consumer” listing, you’d use the next command:
“`
C:UsersUserDownloads> cd ..
C:UsersUser>
“`
Absolute and Relative Paths
An absolute path is a path that begins from the foundation listing of the drive. For instance, the next is an absolute path to the “Downloads” listing:
“`
C:UsersUserDownloads
“`
A relative path is a path that begins from the present listing. For instance, the next is a relative path to the “Downloads” listing:
“`
Downloads
“`
Utilizing the Command Immediate
The Command Immediate is a robust instrument that lets you work together together with your pc at a command-line stage. One of many many instructions you need to use within the Command Immediate is cd, which lets you change directories. To return one listing within the Command Immediate, you need to use the next steps:
- Open the Command Immediate. To do that, you may kind "cmd" into the Home windows search bar and click on on the Command Immediate icon that seems.
- Navigate to the listing you wish to return from. To do that, kind the
cdcommand adopted by the trail to the listing. For instance, if you wish to return to the listingC:UsersJohnDocuments, you’d kind the next command:
cd C:UsersJohnDocuments
- Kind the
cd..command. This command will return one listing from the present listing. - Press Enter. The Command Immediate will now return one listing.
The “CD” Command
The “cd” command in Command Immediate (cmd) lets you navigate via directories and folders within the file system. To return a listing, use the next syntax:
cd ..
It will take you up one stage within the listing construction. For instance, in case you are at the moment within the “C:UsersUsernameDocuments” listing, operating “cd ..” will take you to the “C:UsersUsername” listing.
Going Again A number of Ranges
You can too return a number of ranges within the listing construction utilizing the “cd” command. To do that, use the next syntax:
cd ......
It will take you again 4 ranges within the listing construction. You may add or take away as many “..”s as wanted to return the specified variety of ranges.
For instance, the next command will take you again 5 ranges within the listing construction:
cd ........
It is vital to notice that the “cd” command solely works on directories. It can’t be used to navigate to recordsdata.
Instance
| Command | End result |
| cd .. | Goes up one stage within the listing construction |
| cd …. | Goes up two ranges within the listing construction |
| cd …… | Goes up three ranges within the listing construction |
Guardian Listing with “..”.
To go to the guardian listing of the present listing within the Command Immediate, you need to use the “cd..” command. This command will transfer you up one stage within the listing construction. For instance, in case you are at the moment within the “My Paperwork” listing, and also you wish to go to the “C:” drive, you need to use the next command:
“`
cd..
“`
It will transfer you to the “C:” drive. You can too use the “cd..” command to go to the guardian listing of a selected listing. For instance, in case you are at the moment within the “My DocumentsMy Footage” listing, and also you wish to go to the “My Paperwork” listing, you need to use the next command:
“`
cd..
“`
It will transfer you to the “My Paperwork” listing.
Here’s a desk summarizing the utilization of the “cd..” command:
| Command | Description |
|---|---|
| cd.. | Go to the guardian listing of the present listing. |
| cd..listing | Go to the guardian listing of the required listing. |
A number of Listing Ranges
To return a number of listing ranges in cmd, use the cd .. command with the specified variety of intervals. For instance, cd ... goes again three directories, whereas cd .... goes again 4 directories.
Going Again One Listing
To return one listing, use the cd .. command. This command strikes you up one stage within the listing tree.
Going Again Two Directories
To return two directories, use the cd ../.. command. This command strikes you up two ranges within the listing tree.
Going Again Three Directories
To return three directories, use the cd ../../.. command. This command strikes you up three ranges within the listing tree.
Going Again 4 Directories
To return 4 directories, use the cd ../../../.. command. This command strikes you up 4 ranges within the listing tree.
Going Again 5 Directories
To return 5 directories, use the cd ../../../../.. command. This command strikes you up 5 ranges within the listing tree.
Going Again Six Directories
To return six directories, use the cd ../../../../../.. command. This command strikes you up six ranges within the listing tree.
Going Again Seven Directories
To return seven directories, use the cd ../../../../../../.. command. This command strikes you up seven ranges within the listing tree.
| Variety of Intervals | Variety of Listing Ranges |
|---|---|
| 1 | 1 |
| 2 | 2 |
| 3 | 3 |
| 4 | 4 |
| 5 | 5 |
| 6 | 6 |
| 7 | 7 |
Navigate Again to Root Listing
Navigate again to the foundation listing by following these easy steps:
- Open Command Immediate (CMD) by urgent the Home windows key + R, typing “cmd”, and hitting Enter.
- Kind “cd ” (with out quotes) to go to the foundation listing.
- Press Enter.
Alternatively, use the desk under for a fast reference to navigate again to the foundation listing and different frequent directories.
| Command | Description |
|---|---|
| cd | Go to the foundation listing |
| cd.. | Go to the guardian listing |
| cd Paperwork | Go to the Paperwork listing |
| cd Desktop | Go to the Desktop listing |
| cd Downloads | Go to the Downloads listing |
Automate with Batch Recordsdata
Batch recordsdata present a handy solution to automate repeated duties within the command immediate, together with altering directories. Here is the way to use batch recordsdata for this objective:
- Create a brand new batch file: Open Notepad or another textual content editor and create a brand new file.
- Begin with the @ECHO command: This command suppresses the show of instructions within the command immediate when the batch file is executed.
- Use the CD command: Use the CD command adopted by the listing path you wish to change to. For instance, to vary to the “Paperwork” folder, use the next command:
@ECHO OFF CD Paperwork
- Add extra instructions: You may add another instructions it is advisable execute after altering directories. For example, you need to use the DIR command to checklist the recordsdata within the present listing.
- Save the batch file: Save the file with a “.bat” extension, resembling “ChangeDirectory.bat.”
- Run the batch file: Double-click the batch file to execute it. It’s going to robotically carry out the required listing modifications and another instructions included within the file.
Here is an instance of a batch file that navigates to the “C:UsersusernameDocuments” folder and lists the recordsdata in that listing:
| Batch File Code | Description |
|---|---|
@ECHO OFF |
Suppress show of instructions |
CD C:UsersusernameDocuments |
Change listing to the required path |
DIR |
Checklist recordsdata within the present listing |
How To Go Again Listing In Cmd
To return a listing within the Command Immediate (cmd), you need to use the “cd..” command. This command will take you up one stage within the listing tree. For instance, in case you are at the moment within the “C:UsersYourUserNameDocuments” listing, and also you wish to return to the “C:UsersYourUserName” listing, you’d kind “cd..” into the Command Immediate.
You can too use the “cd” command to return to a selected listing. For instance, if you wish to return to the “C:Home windows” listing, you’d kind “cd C:Home windows” into the Command Immediate.
Individuals Additionally Ask About How To Go Again Listing In Cmd
How do I am going again to the earlier listing in cmd?
To return to the earlier listing in cmd, you need to use the “cd..” command.
How do I am going again to the foundation listing in cmd?
To return to the foundation listing in cmd, you need to use the “cd /” command.
How do I am going again to the desktop in cmd?
To return to the desktop in cmd, you need to use the “cd %userprofilepercentDesktop” command.