Linux Commands Tutorials

In Linux Commands Tutorials we will learn some most important basic and advance Linux commands with examples. Linux is a commands base operating system . So to operate Linux OS one should have some basic knowledge of commands. So let us start.

Linux Commands :

1 . man

The man command is the user manual of commands available in the Linux. If you don’t know how to use a command type man and after that type the command name you want a proper documentation and details like description, syntax, usage etc. It will give you full details.

Syntax :

$ man [options] [command name]

Example :

man command Linux
man command details Linux Unix

2 . pwd

If you want to know in which directory you are in just type command pwd and it will tell you where are you in. pwd means Print Working Directory that is current working directory.

Syntax :

$ pwd [options]

Example :

pwd Linux command

In above image current working directory is /home/bptutorials

3 . cd

The meaning of cd command is Change Directory. It is used to navigate from one directory to another. Suppose we are in dev directory and want to go to var director then we will write $ cd / then cd var

Syntax :

$cd [options] [directory name]

Example :

cd Linux command

To navigate to var directory first we have to go to root( / ) directory then cd var command move to var directory.

cd / : This command represents root directory . Here / represents root directory. When we write cd / in terminal, it change directory from current directory to root directory.

Example :

cd /  in Linux command

cd ~ : This command will change directory to home directory.

Example :

cd ~ command Linux

cd : cd is same as cd~

cd .. : This command change to the parent directory or one level up of current directory.

Example :

cd .. Linux command

In above pic first cd.. move one level up i.e. var directory and second cd.. move to parent directory / .

cd ” dir name” : This command changed to the specified directory with spaces.

Example :

Linux command tutorials cd " dir  name" Linux command

In above pic directory “php programming” include space so we write command like cd “php programming” .

cd dir\ name : This command works same as cd “dir name” .

Share This!

Leave a Reply

Your email address will not be published.