Some missions ideas
October 28, 2021 ยท View on GitHub
-
using
ls -land some other common options -
ls *vsls -d * -
using
less/moreto paginate the output of a command -
meaning of the
PATHvariable -
symbolic links ("Make a secret passage from one room to another.")
-
using
sort/uniq -
filecommand -
diffand/orcmp -
search through the history with
C-r -
history of commands
-
more missions using shell patterns
[...]and[^...](or[!...]as specified by POSIX, but this interacts with bash' history expansion) -
mission using
*/*patterns to explain that/are not captured by wildcards -
simple regular expressions and
grep -
create empty files with
touch, update modification date -
dealing with strange files: spaces (quoting / escaping), starting with a dash (using
--), etc. -
scripting:
forloops on files -
yescommand (not POSIX) and pipes -
pushd/popd -
commto compare before / after file -
paste(restore a torn treasure map) -
join -
wget/curl -
tar/zip- Idea: receive/send a package (archive = packaging).
-
fuser/lsof -
print prime numbers less than N with a combination of
seq/factor/grep/cut -
only activate completion once the first appropriate mission has been completed (put
bind 'set disable-completion' onin the first mission'sgshrc, andbind ... ofin some mission'treasuse.sh) -
"summary missions" to practice what has been learnt at the end of the
missions/basicmission group. We could ask the player o tidy up the pantry, initially filled with a big mess of files (fruits, cheese, meat, wine, trash, ...) and the player would have to organise everything into a specified directory structure: fruits in "barrels", cheese on "shelves", get rid of trash, ... -
manage an inventory (or the
Chest) with aliases:alias inventory='ls ~/Forest/Hut/Chest | nlto show the inventory,alias pick='mv -t ~/Forest/Hut/Chestto pick an item (NOTE: it probably requires GNU'smvwith option-t)alias drop='...'to drop an item at the current location (NOTE: that's probably better to use a function for that, no?)