This is the 13th post of a series for teaching cyber-security in a coding-club. Read [part 12]
Overview
Cowsay
Let's install a new program called cowsay
. Remember you can do that with:
sudo apt install cowsay
Hopefully, it worked. Let's try it out:
cowsay hello
Did that work?
_______
< hello >
-------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||
Let's do more fancy stuff now.
cd /usr/share/dict/
and then
cat american-english | grep moo | cowsay
Can you guess what will happen if you run that?
Can you make the cow say all the words which contain goo
?
Conclusion
What we learned
We have learned lots of new tools and commands in this unit.
- First the fun ones
sl
(the choo-choo train) andcowsay
which prints a speaking cow!
< did you learn anything? >
-------------------------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||
- The Super User command or
sudo
to become an admin and install anything. - The
sudo apt install X
to install program X top
orhtop
to impress your friends with a crazy list of all the hidden programs running on the machine.- the
TAB
to save time with autocomplete. mkdir
,mv
,cp
,rm
to create directories, move them, copy them or delete them. (mv
,cp
andrm
can also move, copy and remove files)du -h
to see the disk usage in all the sub-directories- The use of pipes
|
to send one command to the next command, to the next command, and so on! In particular piping things towc
to count the lines or words.
Except for cowsay
and sl
, these tools will be useful before and after entering the secret server!
In the next posts you’ll learn how to connect your shell to the internet and find other computers and servers online. Let's go to [Part 14].