THE TERMINAL FOR ROOKIES

Hello people! Today we will quickly show tricks and basic commands to the terminal on GNU / Linux.

Open the terminal

Open the application menu and locate the terminal application. You can open the terminal by pressing Ctrl + Alt + T.

Run a command

Type the command and press the ENTER key.

Close or leave the terminal

Run the command exit

Stop the execution of a command

To stop the execution of a command, either because it is taking too long or because he hung up, press Ctrl + X.

autocomplete

We can autofill pressing the TAB key either to finish writing a command or to show us that there are options available.

Complete the command

Show commands starting with ...

Complete folder addresses

Show parameters available for a command

Show package names starting with ...

Navigating folders (directories)

Display the contents of a directory.

ls

Show list details

ls -l

Show hidden files and folders

ls -a

Parameters can be combined to display the list of details including hidden files.

ls -la

In GNU / Linux to convert a file hidden file, simply the name starts with a dot, the same applies to folders.

Getting in and out of folders

Enter a folder

cd carpeta

Exit a folder

cd ..

Display the full path of the current folder

pwd

See text file

Show a text file

less archivo

With less You can search for a word in the text

  • Buscar : / + palabra + ENTER
  • Buscar próxima : N
  • Buscar anterior : Mayúsculas+N

To get out of less press the Q

Manuals commands

The command man shows the manual commands

man [comando]
man ls
man cd

man uses the same navigation and search less. To exit, press the Q key

See the file type

The file command displays the file type regardless of whether it has changed the extension or no extension.

file archivo

Edit text files

nano editor is simple and easy to use text to the terminal, at least much easier to use than vi.

nano archivo

Use the arrow keys to scroll through the text. To exit, press the Ctrl + X keys, then you will be asked if you want to save the changes.

On the menu the symbol '^' is replaced by the Ctrl key, so

^ X = Ctrl + X

This is enough for newcomers to the terminal, at least for a while. The terminal is a powerful and lightweight tool, gradually more and more are memorizing commands, to acquire such comfort, you prefer to perform many tasks on the terminal above do it in a graphical interface. I hope this article is helpful to facilitate the introduction and use of terminal novice to the world of GNU / Linux.

bonus

Create empty file

touch archivo_nuevo.txt

Restart

sudo reboot

Another way to restart

sudo shutdown -r now

To turn off

sudo shutdown -P now

Off at 02:30 pm

sudo shutdown -P 14:30

Off in 30 minutes

sudo shutdown -P +30

Monitor command

watch -n [segundos] [comando]

watch run the command every few seconds, to stop watch press Ctrl + X.

watch -n 1 date
watch -n 10 df -h /dev/sda1

4
What do you think about it?

please Enter to comment
5 Comment threads
0 Responses thread
1 Followers
 
Comment with more reactions
Highly Commended thread
5 Authors comments
Elif12019Deepin en EspañolCharlsHiram Higuera Authors of the most recent comments
subscribe
Newer oldest More popular
Report of
f12019
Member

Very good contribution and thank you for thinking of us newbies

Charls
Member

Thanks for the information, very useful.

Deepin en Español
Admin

Thank you very much for contributing to the community. Because the world of the terminal is large, we have moved to a subcategory dedicated to it: "Using the terminal". We hope that is of great...Read more »

Hiram Higuera
Member

Excellent manual, thank you.

Eli
Publisher

Very interesting article Isaías Gätjens MIsa Gätjens M, Straight to the point but clear.