What are games to play from a Linux terminal

Last updated on December 22, 2020 by Adrien Brochard

Who never procrastinated and played games instead of writing a paper, finishing a report, or looking after the kids? Absolutely no one. But when Linux users procrastinate, they procrastinate in style: while playing from the terminal! We tend to forget, but at first a graphical interface was not necessary for a good game. And thanks to open-source and the community, many arcade and other good games were ported to be played from within a terminal, without an X server running. It would be impossible to list them all, but let me present ten of these games that particularly appealed to me personally.


Let's start the list with a Pac-man clone, MyMan. Pac-man is the famous arcade game from the 80's, and is still today one of my favorite games. The rules are simple: eat all the balls while avoiding the ghosts, or eat the fruits and chase down your attackers. Only the arrow keys are needed to control your character.

To install the game, you will need ncurses and groff present on your machine.

On Ubuntu or Debian:

$ sudo apt-get install libncurses5-dev groff
$ wget http://downloads.sourceforge.net/project/myman/myman-cvs/myman-cvs-2009-10-30/myman-wip-2009-10-30.tar.gz
$ tar xvfvz myman-wip-2009-10-30.tar.gz
$ make
$ sudo make install
$ myman

On Arch Linux, the game is available on AUR.

2. nInvaders

To continue with old arcade games, it would be impossible not to mention nInvaders, the clone of the famous Space invaders. Control the ship at the bottom of the screen, and defend the earth from waves of enemies. Use the arrow keys to side scroll and the space bar to shoot.

To install on Ubuntu/Debian, just run:

$ sudo apt-get install ninvaders

or install from AUR on Arch Linux.

3. Moon-buggy

Finally, my last arcade favorite is moon-buggy. Inspired by Moon Patrol from 1982, the game lets you control from the side view a vehicle driving on the moon. The goal is simply to survive for the longest time possible by jumping over the holes with the space bar, or shooting with the a key. But the hit boxes are extremely punitive, and the game always oscillates close to insane frustration: a real pleasure.

Check it out on Ubuntu/Debian with:

$ sudo apt-get install moon-buggy

or on the AUR for Arch Linux users.

4. Bastet

Let's leave the realm of the arcade for the one of really really really addictive games. What better game to start with than a Tetris clone, Bastet? No need to go over the details here: pile up the blocks with the arrow keys, rotate them with the space bar, and get as many points as you can!

To install it on Ubuntu (since Saucy):

$ sudo apt-get install bastet

or check out the AUR on Arch Linux.

5. 2048.c

Talking about addictive games, have you heard about 2048? Because you really wanted to play it from the terminal, here is 2048.c, a version of 2048 coded in C. The goal is to obtain a block of value 2048 by fusing blocks together with the arrow keys. If you have never played it before, I will not say more as the game is intuitive and so pleasant to discover.

To install it on Linux, run:

$ wget https://raw.githubusercontent.com/mevdschee/2048.c/master/2048.c
$ gcc -o 2048 2048.c
$ ./2048

For Arch Linux, use the AUR package.

6. Greed

Maybe the hidden child of Tron and Pac-Man, Greed is an interesting game with a very colorful interface. The goal is to eat as many digits as possible using the arrow keys (hence Pac-Man), but the value that you intend to eat will also be the number of steps you will make in its direction. For example, if you are next to a 3 and press left to eat it, your character will take three steps to the left, eating every digits encountered. But the trap is that it is not possible to revisit where you already ate. In other words, the black trace is a wall (hence Tron).

To install on Ubuntu/Debian, run:

$ sudo apt-get install greed

or install the AUR for Arch Linux.

7. Ski

One of those games that require a bit of imagination, but really builds up to excitement, Ski lets you incarnate a skier trying to avoid the danger of the mountain and a hunting yeti. The controls are a bit less intuitive, and I invite you to type ? to see the help. The idea is to move left or right or even teleport to survive.

For Ubuntu/Debian, download it here, extract the archive, and inside run:


For Arch Linux, install it from AUR.

8. NetHack

Here we are, the monument of ASCII games, the foundation of a real cult, NetHack. It is not the only good roguelike game on Linux, and there are thousands of clones which are completely worth playing, but this is the one that sets the crowd on fire. The commands are numerous, and it really is indispensable to look up the manual, but the base is there: a dungeon crawling with monsters, a lot of character stats, a labyrinth created via procedural generation, and a lot of deaths. If you are a fan of roguelikes, definitely check it out.

On Ubuntu/Debian:

$ sudo apt-get install nethack-console

On Arch Linux:

$ sudo pacman -S nethack

9. cgames

Another game that I really enjoy is Sokoban, the logic game where you have to push crates up to a target. However I found much better than just a game of Sokoban to play from the terminal, I found a whole pack of logic games to play from the terminal. The program cgames contains csokoban, cmines, and cblocks, which are all respectively a game a Sokoban, of minesweeper, and of sliding-block puzzle.

To try it out on Ubuntu/Debian, dowload it from the official page, extract and from the directory run:

$ sudo apt-get install libgpm-dev libncurses5-dev
$ ./configure --with-ncurses
$ make
$ sudo make install
$ csokoban (or cmines or cblocks) to launch the respective games

And as usual, the package is in AUR for Arch Linux.

10. BSD-Games

Finally, it would be awful not to talk about BSD-Games. This package is a small library of games and fun applications. To cite only a few, you can find a hangman, a banner utility, a program to decrypt Caesar cyphers, a Star Trek simulator, and a funny reference to the movie WarGames. Here is the link to the complete list of applications.

To install, run:

$ sudo apt-get install bsdgames (on Ubuntu/Debian)
$ sudo pacman -S bsd-games (on Arch Linux)

As a conclusion, I would like to applaud the blog ttygames.wordpress.com for trying to list all the terminal games out there. I stumbled upon it while looking for the various clones of NetHack. I got to say that the work done is pretty impressive. Bravo!

Like I said in the introduction, it would be impossible to list all the games out there (hurrah for open source!), but if you really like a game not listed here, please feel free to share it. Maybe we'll do another list in a future post.

Support Xmodulo

This website is made possible by minimal ads and your gracious donation via PayPal or credit card

Please note that this article is published by Xmodulo.com under a Creative Commons Attribution-ShareAlike 3.0 Unported License. If you would like to use the whole or any part of this article, you need to cite this web page at Xmodulo.com as the original source.

Xmodulo © 2021 ‒ AboutWrite for UsFeed ‒ Powered by DigitalOcean