Friday, February 10, 2017

HOW TO NAVIGATE BETWEEN FOLDERS IN LINUX USING COMMAND LINE

CD command which is similar to windows command.
CD means change directory.

Example:
For our example lets assume the following directory structure

     root/test/etc/etc1

Task 1:  Command to navigate from etc to etc1 folder i.e., from higher level folder to lower level folder. i.e., from etc to etc1 folder

CommandCD etc1 

Task 2:  Command to navigate from etc1 to test folder i.e., from higher level folder to lower level folder. i.e., from etc to etc1 folder

CommandCD  /test

Note : Unlike windows type the full path for navigation to folders with correct spelling.


 For example to navigate to root folder type the command CD /




 

 After navigation to root folder type LS the list command it will display all the folders in root folder


to navigate to lower folder  etc type command cd etc


I have navigated to perl folder in etc folder

 now i have navigated backed to etc folder with the command cd /etc

Note : Important thing to note is for navigation to lower folder use cd navigation path and to navigate to upper folders use cd /Navigation path.
           use ls command to display the list of folders.

1 comment:

Beready.pk said...

Nice and very helpful post sharing here. And nice work great blogpost.
Jobs in Lahore 2020