ANSI escape sequences
PAINT YOUR BASH
This month, we’ll show you how to decorate your console and give it a fresh new look by adding color to the command line with ANSI escape sequences.
Black on white, or white on black – a terminal doesn’t need to be so boring. Any modern Linux console can display colors to brighten up program output, welcome messages, and even the shell prompt. This article shows you how to add a touch of color and decorate your command line.
The Color Palette
Some programs have their own parameters for adding color to output. Both ls and grep support a --color option that makes command output easier to read (Figure 1). ANSI escape sequences provide the underlying mechanism for this. To get a line of colored output with echo in Bash, you can add an escape sequence to the text (Listing 1).
Buy this article as PDF
Carnegie Mellon researchers say 3 million pages could fall down the phishing hole in the next year.
The US government rolls new best-practice rules for protecting SSH.
Klaus Knopper announces the latest version of his iconic Live Linux system.
All websites that use these popular CMS tools could be vulnerable to denial of service attacks if users don't install the updates.
According to a report, many potential victims of the Heartbleed attack have patched their systems, but few have cleaned up the crime scene to protect themselves from the effects of a previous intrusion.
DARPA and NICTA release the code for the ultra-secure microkernel system used in aerial drones.
Should you trust an online service to store your online passwords?
New B+ board lets you build cool things without the complication of a powered USB hub.
Redmond rushes in to root out alleged malware haven.
New initiative will bring futuristic virtual reality effects to the web surfing experience.