unix-command-tutorial

When you first open the terminal, the first command you may type could be:

ls

It will display the contents of the current directory.

 

If there is nothing in it, it will not display anything.

A current alias for this command, is:

ll

This is an alias for:

ls -l

The -l option, asks the request to the ls command to display more informations.

If there is nothing in the current directory, it will probably display:

.  ..

with the ls -a option.

It is also possible to combine several options: ls -al.

You can probably create a new directory with the mkdir command:

mkdir dir_name

You can later remove this directory with rmdir:

rmdir dir_name/

This operation will be operated, only if the directory is empty,

otherwise it will display:

directory not empty

When ls is invoked with -a, the two characters . and .. are there to stand for:

If you try to type:

cd .

You will just stay at the current place.

cd dir_name/

is a cmd which means: change-directory.

cd

If you type it with-no arguments it will change you to the default start - dir.

You can create a new file in the current dir w/ vim:

$ vim file.txt
:wq

type the :wq to exit.

It will leave w/ an empty file.

Learn more vim w/: vim-tut.

versions of this file.