Skip to main content

Play Tetris and text-based games hidden in your Mac’s Terminal

terminal-doctor_dt
Image used with permission by copyright holder

Has modern gaming got you down? Do you long for the days of Oregon Trail? Is Tetris the pinnacle of gaming for you? If so, MacLife uncovered a few games buried in your Mac’s Terminal shell using a program called emacs (not to be confused with the Apple eMac). While Terminal may look like the equivalent of the business-front to the party-back of OS X’s graphical interface, it’s useful for programming and digging deeper into the UNIX base that OS X is built upon. Plus, there are a few treats buried within it.

While Call of Duty isn’t secretly buried within your Mac, there are at least four different games built into emacs that are accessed via the Terminal, including a very basic version of Tetris, a text-based adventure game, and even a “psychotherapist” who reads like a joke psychoanalyst crossed with the attitude of Siri. There’s also a program that generates random patterns made out of “@” signs that’s oddly hypnotic to watch.

So how do you access these slightly hidden games? First, open the Terminal either from the Applications folder or by searching for it. At the command prompt type “emacs,” then hit the enter key. Next, press the ESC key and then the letter “x.” For Tetris, type in “tetris” and hit enter. For the psychotherapist, type “doctor,” and for the random “@” patterns, type “life.” Hit enter after each command. If you’re unable to input a command, press the ESC key and “x” again. 

Accessing the text adventure takes a little more work. At the command prompt when you first open Terminal, type “emacs -batch -l dunnet” and press enter. Navigate around the game by entering commands such as “Take shovel” or “Go southeast.” Typing “help” will give you a full list of commands as well as tips for playing the game. Have fun! 

Editors' Recommendations

Topics
Meghan McDonough
Former Digital Trends Contributor
Meghan J. McDonough is a Chicago-based purveyor of consumer technology and music. She previously wrote for LAPTOP Magazine…
How to back up your Mac and keep your files safely stored
A MacBook Pro on a table in front of a window.

We all know we should back up our computers in case something goes wrong, but many people are put off by what seems like a complicated process. Luckily, it’s very easy to back up your Mac, and there are plenty of options open to you, meaning you can find one that suits you best.

Read more
How to delete a user on your Mac and free up disk space
Two people use iMacs on a desk in an office.

If you have an account on your Mac that’s no longer used and is taking up valuable disk space, you can remove it in just a few steps. Our guide will take you through everything you need to do to delete a user on a Mac quickly and easily.

Read more
5 reasons your MacBook keeps restarting and how to fix it
A person Macbook Air (2018) Review.

If your MacBook is in a restarting death spiral, it's important not to panic. Any one of the fixes we go through in this article could alleviate your issues. Some of the common causes of looping restart issues on a MacBook include:

Out-of-date MacOS
Software issues
Peripheral devices causing a malfunction
Settings that need to be reset
A flaw in MacOS that requires reinstallation

Read more