NoSleep for Mac OS X is a program to prevent your MacBook from sleeping. On a MacBook Air, MacBook Pro, or Macbook with traditional clamshell mode, an external display, mouse, and keyboard must be attached in order to maintain the running closed-lid clamshell state. Thanks NoSleep we can now remove those hardware limitations and run a Mac laptop with the lid closed and no hardware attached.
The problem I was facing was that when I had a keyboard, trackpad, and external monitor attached and removed the power supply / power adapter my macbook would go to sleep.
Now thanks to NoSleep I can easily toggle the sleep mode to keep the computer awake.
This is similar to the Caffeine extension which can keep your monitor awake during presentations – it also sits in the menu bar.