Are you sick of reading cryptic manuals and boring articles for learning Linux? Look no further, because you can learn Linux by playing games. It’s not only fun but also quite engaging. Moreover, all of them are free to play, and some are even open-source.
6OverTheWire Bandit
OverTheWireis a collection of wargames that teach you different cybersecurity concepts. Wargames are essentiallyCTF-stylechallenges where you need to complete a specific task to reach a goal. The Bandit wargame focuses solely on Linux. It has over 30 levels, increasing in difficulty.
In each challenge, you need to complete a task such assearching for a fileandreading it. The only way to get to the next level is by completing the current one and retrieving a special password that will allow you to advance.
To complete each challenge, you need toconnect to their Linux server via SSHand use different Linux commands. This allows you to familiarize yourself with various Linux commands and concepts in a gamified and challenging environment. You get access to a full-fledged Linux system.
What stood out to me about OverTheWire is that it doesn’t do much hand-holding in your learning process and forces you to do your own research. The levels are also designed to resemble a real-life Linux system that you would encounter in everyday situations. This kind of learning style solidifies your understanding and helps you implement it practically.
5Terminus
Terminusis a terminal-based “choose your own adventure” type of game where you use Linux commands to go on an adventure inside the command line. Developed by some students at MIT, the game is designed to teach players about command line interfaces through an engaging and interactive gameplay experience.
The game includes various locations and items. To go to locations, you have to usethe cd command. For interacting with items, you havethe less command. To check what paths and items are in a location, you usethe ls command. You also have the pwd command to see where you are currently.
I like how the game has some graphical images to give you a more game-like feeling, something you usually don’t find in many terminal-based games. The graphics show the location of where you currently are, the items or persons you interact with.
If you love adventure games, you’ll love Terminus, no matter how proficient you are with the command line. As a cherry on top, you can learn to useseveral important Linux commandsby playing the game.
4Vim Adventures
Vim Adventureshas only one purpose: to make you anexpert at using Vim. In case you didn’t know, Vim is a popular text editor that’s also notorious for being difficult to use. The reason many find it difficult is that it’s fully terminal-based. Moreover, you need to know specific commands to operate it.
Vim Adventures is a 2D adventure game where you may only use Vim controls, shortcuts, and commands to play the game. The setup is like an adventure puzzle game. You move through mazes, solve puzzles, collect items, talk to people, and so on. The game is effective for practicing and memorizing different Vim commands.
You start with four buttons: h, j, k, and l for moving around the maze. By progressing through the game, you’ll have to collect other keyboard buttons. I liked how the game forces you to learn each Vim concept visually and through its keybindings so that you don’t miss anything.
The base game is free to play online in your browser. There are also options to buy licenses. Buying licenses unlocks some extra perks, such as extra challenges to train your muscle memory. If you finally decide to learn Vim, give this game a shot. You’ll love it.
3clmystery
clmysteryis a murder mystery-themed game where you need to investigate files and clues to find out the main culprit. The game is played on the command line, and you’ll have to use Linux commands to interact with the game files.
To play the game, you’re able to eitherclone the GitHub repositoryordownload it as a ZIP file. Once done, you can start playing by reading the instructions file. On top of the game’s files, the repository also contains hints that will help you reach the goal faster.
But what I appreciate even more is the inclusion of acheatsheet for Linux commands. This file is a big collection of several useful Linux commands and how to use them. It’s quite detail-oriented. Even if you don’t play the game, the cheatsheet is worth looking into.
The game requires you to read a lot of content and do some thinking. If you like crime-solving games and don’t mind a bit of command line in the mix, it’s a fun way to learn Linux.
2bashcrawl
bashcrawlis similar to Terminus in the sense that both are terminal-based choose-your-own-adventure games. The setting is similar too. You start at a location, interact with items, go to different locations, and explore your surroundings. Everything is done through Linux commands.
The more you progress through the game, the more commands you learn, with their arguments. The game felt more engaging because it has a lot of commands that perform different activities in the game. For example, you can usethe export commandto add items to your inventory and check your items usingthe echo command.
Unlike other games on the list, bashcrawl has a lot of text files called scrolls. These files contain the basics of how to use each command and what they do. So, you’re not only learning through playing but also the concepts behind each command.
You can get the game from the linked GitLab repository or play it online on aJupyter Notebookinstance. However, the online sessions may feel disruptive sometimes due to connectivity issues. So, I recommend downloading the source file locally for the best experience.
1cmdchallenge
cmdchallengebrings a different taste to this list. It doesn’t directly teach you any Linux commands. Instead, it gives you challenges to solve that require looking up those commands. So, for example, it’ll ask you to create a file and move it to a certain directory. To beat the challenge, you need to input the command to do that.
The game starts with pretty basic commands and gradually becomes difficult. By completing each challenge, you get an emoji and move to the next challenge. If you get stuck, you can check the solution. One thing I liked here is that it lists every possible solution to the challenge. This allows you to learn the tidbits of the command you need to use.
There are two more versions of this game found on the same website. In one version, you can’t use bin/ commands, forcing you to use shell built-ins. The other version contains more advanced commands as well as command basics on top of just solutions.
If you’re already familiar with Linux commands, try cmdchallenge to hone your skills and test how good you really are. You can also try the other two versions for some extra challenge.
With so manyfun resources to learn Linuxnowadays that there’s no excuse not to learn it. You can also followmany tricks that make the command line easier. If you still feel stuck, you can alwaysrefer to the manuals.