Wednesday, 29 January 2020

6 Fun and Cool Mac Terminal Commands to Try

mac-terminal-cheatsheet

The Terminal is a handy utility that’s commonly found on UNIX-based computers, such as Linux and macOS. In it, you can type in commands to make your computer perform certain tasks. If you’re familiar with Windows, it works a lot like the Command Prompt or PowerShell.

Unlock the "Essential Linux Commands Cheat Sheet" now!

This will sign you up to our newsletter

Enter your Email

While you might think of it as a serious component of your computer, there are fun things to do in the Terminal. If you aren’t familiar with Terminal’s interface, that’s okay. Regardless of your experience level, you can use these cool Terminal commands without much effort.

1. Play Old-School Games

macOS comes with GNU Emacs, a text editor that’s part of the GNU operating system. You can access it via the Terminal. By itself, the explanation might not mean a lot to you. But it does mean you’re able to play a selection of retro games with a few simple inputs into Terminal.

If you need a short distraction, most of these games have a quick pace to them. This lets you get a few rounds in without much of a time investment. However, if you leave early on some of these games, your suddenly sassy AI partner might heckle you a bit.

Mac Terminal Game List

To begin playing, simply follow these steps:

  1. Open Terminal.
  2. Type in emacs and press Return.
  3. Hold down Fn and press F10.
  4. Either use the up/down keys or hit the T key to select t for Tools.
  5. Again, either use the up/down keys or hit the G key to select g for Games.
  6. Select a game from Terminal’s list using the up/down keys, or enter its respective hotkey. The list of games is as follows:
  • 5×5
  • Blackbox
  • Towers of Hanoi
  • Multiplication Puzzle
  • Solitaire
  • Zone Out
  • Adventure
  • Gomoku
  • Life
  • Snake
  • Tetris

Just remember when selecting your game by hotkey to use the appropriate case (i.e. a capital T for Tetris), as some of them share hotkeys.

macOS terminal tetris

If you want to quit the game, use the key combination Ctrl + X followed by Ctrl + C.

2. Watch ASCII Star Wars in the Terminal

star wars terminal ascii art
In a surprising inclusion, you can watch Star Wars: Episode IV—A New Hope in ASCII art. If you feel like watching a sci-fi classic re-imagined, just set aside some time. You’ll need a live internet connection or this fun Terminal command will fail.

If you have an IPv6 address, a few scenes will be slightly different. It’s an old joke that having an IPV6 address displays the movie in color, but that’s not actually the case.

When you’re ready, open up Terminal. Depending on your macOS version, type in one of two commands:

  • For macOS Sierra and later: nc towel.blinkenlights.nl 23
  • For macOS versions earlier than Sierra: telnet towel.blinkenlights.nl

3. Talk With Terminal

Do you have a lot of time to spare but no one to spend it with? You could have Terminal keeping you company during those quiet moments.

Just type in: say (Insert text here without parentheses)

You can type in any text you want after the say prompt and Terminal will speak it out for you. As one of the simplest tricks to do, it’s a cool Terminal command to prank others with.

If you like, you can even customize the voice by going to System Preferences > Accessibility > Speech and selecting your preferred speaker.

4. Meet the Psychotherapist

If you had some fun getting Terminal to talk to you during quiet times, there’s another cool Terminal command to try. This will allow you to engage in a more active therapy session.

If you’re suffering from stress at work, it can serve as a free alternative to an actual therapist.

terminal psychotherapist

To consult Emacs’s virtual psychologist with your problems, follow these steps:

  1. Launch Terminal.
  2. Type in emacs and press Return.
  3. Press and hold down Shift, then press Esc.
  4. Press the X key.
  5. Type in doctor and press Return.
  6. Type in what you want to say and press Return twice.
  7. Let the conversation go until you’ve had your fill.

If your psychotherapist starts suggesting you need a break, try some light reading such as our Mac Terminal commands cheat sheet.

5. Get Your Weather Forecast

While some of the other fun Mac Terminal commands are pretty silly, this one is actually useful. If you need a three-day forecast of your local weather conditions, you don’t even have to open your browser.

Simply open Terminal and type in curl http://wttr.in/ to bring up your local forecast. You’ll instantly receive a breakdown of your morning, afternoon, evening, and night conditions, plus the current weather.

terminal weather report

6. Endless Text Boxes

As with the “say” prompt mentioned above, the simplest commands in Terminal make for great pranks. If you ever want to surprise anyone on their Mac, try taking advantage of the yes command. This makes Terminal spit out the same string over and over until you tell it to stop.

Before you do this, you should know that the yes command utilizes a lot of your computer’s CPU; it prints text so rapidly that the process consumes all available resources. Running multiple iterations of yes will each max out a core of the computer’s CPU, so you must be careful with it.

Thus, we recommend that you only use this prank when the owner will soon see it. You don’t want their computer to run for hours at 100% CPU usage, which could eventually cause damage.

To use yes, follow these simple steps:

  1. Open Terminal.
  2. Type in yes followed by a word or sentence (for example, yes Are you scared?) and hit Enter.
  3. Enjoy the prank results.
  4. Press Control + C to stop the process.

Yes command in Mac Terminal

Enjoy the Command Line With Cool Terminal Commands

After playing with these command lines a bit, you should realize that the Terminal isn’t as boring as you thought. And they aren’t exclusive to macOS—Linux users should be able to access them without issue as well.

For a lot more Terminal command exploration, check out our beginner’s guide to using the Mac Terminal.

Read the full article: 6 Fun and Cool Mac Terminal Commands to Try



from MakeUseOf https://ift.tt/2RAXVMU
via IFTTT

No comments:

Post a Comment