How Can I Quickly Learn Terminal Commands?


A mouse click will only get you so far in Ubuntu. Learning terminal commands is an important step for anyone who's serious about using "the other OS." The experts at Ask Ubuntu provide guidance on the best way to learn "the shell."
It seems to me learning how to use the terminal is a prerequisite to learning how to use Ubuntu. So I'm trying to figure out the best way to learn. Is there a Quizlet online flash card set out there? A better way?
See the original question here.

Randomized Learning (Answered by Radu Rădeanu)

You can add the following line (command) at the end of your '~/.bashrc' file:
echo "Did you know that:"; whatis $(ls /bin | shuf -n 1)
Every time you open the terminal you will learn something about a random command.
If you want some fun, you can use 'cowsay' "utility". To install it, run this in terminal:
sudo apt-get install cowsay
Then add the following line at the end of your '~/.bashrc' file:
cowsay -f $(ls /usr/share/cowsay/cows | shuf -n 1 | cut -d. -f1) $(whatis $(ls /bin) 2>/dev/null | shuf -n 1)
Or you can add the above line as alias in '~/.bash_aliases'. I added:
alias ?='cowsay -f $(ls /usr/share/cowsay/cows | shuf -n 1 | cut -d. -f1) $(whatis $(ls /bin) 2>/dev/null | shuf -n 1)'
Whenever you get bored, you can type in terminal: '?' (followed by Enter). It's like playing dice by yourself.

Whatis (Answered by Achu)

I used to play with 'whatis'. It's not exactly a game, but it's a relatively easy way to learn. For example, type whatis sudo apt-get update and it returns
![whatis sudo apt-get update]
Before I execute any command, I hit it with 'whatis' first. I learn what I'm going to do, then I will do the command with confidence.
If 'whatis' doesn't provide much information or if it's unclear to me, I will go to and read the 'man'.
For example, man sudo.
Google gives you so much info here, sources inside Ask Ubuntu and outside. Here, LMGTFY: best way to learn terminal commands on Ubuntu.

A Game (Answered by snim2)

Yes, Terminus is once such game that will help. There is a live version here. And the code is on github. It's a neat idea, although I rather wish the code was more easily extensible.

Terminal Isn't a Prerequisite to learning Ubuntu (Answered by avernet)

Ubuntu was designed to be very user friendly. Learning how to use the terminal is not a prerequisite to learning how to use Ubuntu. It is, however, if you want to become a power user or troubleshoot problems yourself.
To answer your question, I don't know of any games designed to help or teach shell commands, but I would highly recommend the following resources bash and system administration related:

How Can I Quickly Learn Terminal Commands? How Can I Quickly Learn Terminal Commands? Reviewed by Krutik on 11:15:00 Rating: 5

No comments:

Powered by Blogger.