Jan 27

Modern Day Bully

Jan 27

How To Buy Microsoft Vista

Jan 27

Doing The 1080p

Spotted on: DavisFreeberg.

Jan 27

I just stumbled upon a couple of awesome Mac shortcuts that make it extremely easy to take a screenshot.

Without further a due, here they are:

  • Command-Shift-4: presents a crosshair cursor so that you can take a screenshot of the selected area (saved to Desktop as a png file).
  • Command-Shift-3: Takes a screenshot of the entire desktop (saved to Desktop as a png file).

Screenshot OSX

There are also two variations on the previous commands. Both of these commands capture the same area however, instead of saving an image to the desktop, these commands will save the screenshot to the clipboard so that you can then paste it into another app.

  • Control-Command-Shift-3
  • Control-Command-Shift-4

Pretty cool hunh? Hat Tip: Apple Pro Tips.

Update: I just read over at MacDevCenter.com that OS X also ships with a utility known as Grab which allows you to take even more advanced screenshots. I’ll give it a try and let you know how it works.

OS X Grab

Jan 27

Here’s how to colorize output from the ls command in OS X Terminal.

Edit ~/.bash_profile and add the following two lines:

export CLICOLOR=1
export LSCOLORS=ExFxCxDxBxegedabagacad

This will generate output with the following color scheme:

  • directory: bold blue, default foreground or background
  • symbolic link: bold magenta, default foreground or background
  • socket: bold green, default ” or ”
  • pipe: bold brown (usually shows up as yellow), default ” or ”
  • executable: bold red, default ” or ”
  • block special: blue foreground, cyan background
  • character special: blue, brown background or foreground
  • executable with setuid bit set: black foreground, red background
  • executable with setgid bit set: black foreground, cyan background
  • directory writable to others, with sticky bit: black foreground, green background
  • directory writable to others, without sticky bit: black foreground, brown background

OS X Terminal

OS X Terminal

For those of you who really want to know what this means, here’s some information taken directly from the man page for ls.

LSCOLORS: The value of this variable describes what color to use for which attribute when colors are enabled with CLICOLOR. This string is a concatenation of pairs of the format fb, where f is the foreground color and b is the background color.

The color designators are as follows:
a black
b red
c green
d brown
e blue
f magenta
g cyan
h light grey
A bold black, usually shows up as dark grey
B bold red
C bold green
D bold brown, usually shows up as yellow
E bold blue
F bold magenta
G bold cyan
H bold light grey; looks like bright white
x default foreground or background

The order of the attributes are as follows:
1. directory
2. symbolic link
3. socket
4. pipe
5. executable
6. block special
7. character special
8. executable with setuid bit set
9. executable with setgid bit set
10. directory writable to others, with sticky bit
11. directory writable to others, without sticky bit