Exercises for the command line interface module
Fork
this repository under your GitHub profile andclone
it. Read the instructions andcommit
andpush
your code to the same repository.
Each exercise is described on this page.
Open and close a terminal window. Learn the shortcuts to open/close new tabs
Use the exit
command as well.
What do the following key strokes?
- Ctrl + c
- Ctrl + l
- Ctrl + k
Use the commands
ls
,tree
,cd
andpwd
and navigate into the file sturcture.
What does this command do?
cd
cd -
cd ..
Use some options with ls
ls -l
ls -h
ls -a
Can you combine them?
Use the command
mkdir
to create folders
Go to ex2
folder and create the following structure:
src/main/java/tech.weignite/api/services
and src/test/java/tech.weignite/api/services
use
touch
to create empty files andrm
to delete them. Delete some folders.
Go to ex4
folder and do the following:
Try cat > test.txt
, type some characters, new lines with return
, terminate input with ctrl+d
Do you see the difference with cat >> test.txt
?
Try cat test.txt > new_test.txt
and after cat test.txt >> new_test.txt
. What is the difference between >
and >>
?
Use |
and sort
to sort the unsorted.txt
file.