The best and most concise explanation of stock options and venture funding.

Posted on February 26th, 2013 in startups | No Comments »

Venture Deals was a fantastic read but was primary focused on the viewpoint of an entrepreneur getting his first investment without getting ripped off. This article, in 20 pages summarizes amazingly well what stock options are for startup employees and everything else around it.

http://www.scribd.com/doc/55945011/An-Introduction-to-Stock-Options-for-the-Tech-Entrepreneur-or-Startup-Employee
Edit: The above link should be the most recent (3rd Edition) but the latest is always kept on David Weekly’s site: http://blog.dweek.ly/introduction-to-stock-options-startup-founder-entrepreneur-employee/

Recover photos and other media from a corrupt disk via command line for free.

Posted on January 25th, 2013 in make life easy, productivity | No Comments »

I lost some photos when my camera jammed on the last day of my vacation. Did a little research and discovered PhotoRec (mac download), a command line utility to recover images and other media off corrupt memory card or disk drives for FREE.

Every other recovery app wants to hijack your data and charge you from $40-80 or more to recover it. Gotta love open source. Kudos to this guy Christophe Grenier who wrote it.

http://download.cnet.com/TestDisk-and-PhotoRec/3000-2248_4-10511775.html (available for all platforms, not just Mac)

Yes Virginia, you do need to defrag your Mac.

Posted on January 24th, 2013 in mac | 12 Comments »

After coming back from vacation I found my Mac unusually slow. Previewing a photo in Finder would cause the OS to beachball for a few seconds before finally showing the photo. It made sorting through all the media (25GB of photos and videos) quite painful.

I tried everything from restarting the OS to clearing ample disk space and nothing seemed to help. 2.2 Ghz of Intel Core I7 processer and 16 GB of ram seemed powerless to a 6MB photo. I started suspecting it was a hard disk problem as seek times seemed to be the major issue.

Researching the topic, it turns out that OS X runs a cron job at 3am for various maintenance task including defragging all files over 20MB. The problem is two fold: I have hundreds of files under 20MB and I always put my computer to sleep when I’m not using it because I actually care about the environment.

From Apple’s official doc:

“If your disks are almost full, and you often modify or create large files (such as editing video, [...]), there’s a chance the disks could be fragmented. In this case, you might benefit from defragmentation, which can be performed with some third-party disk utilities.”

Followed by this gem here: “Another option is to back up your important files, erase the hard disk, then reinstall Mac OS X and your backed up files.”

I went ahead and researched the best defragger for the Mac, iDefrag. (More reviews on it here.)

iDefrag screenshot

I ran the demo first which just reviews your system and then just ended up paying the $30 to buy the software and give it a try.

iDefrag is pretty like most Mac apps and gives you a boatload of useless information. They should strip it all and just have one piece of info after analyzing your system: what percent is it fragmented. This information was probably on one of the analysis pages but I sure couldn’t find it. I set the Mac to reboot and run iDefrag overnight in it’s non-OS mode. I woke up the next morning and my computer is now as fast as the day I bought it with all my photos and videos included this time.

Conclusion: If you constantly increase and decrease the size of your hard drive with lots of little files, do any kind of video editing, and/or don’t regularly leave your machine running all night then get iDefrag. It works.

Resize the root EBS disk on an EC2 instance

Posted on January 16th, 2013 in AWS | No Comments »

Running out of space on your EC2 instance? Here’s a great writeup on resizing the root EBS disk to something beefier. It requires having installing Amazon command line tools through another EC2 instance you have running. Works great.

http://alestic.com/2010/02/ec2-resize-running-ebs-root

Convert Epoc time to a real local date in JavaScript.

Posted on December 7th, 2012 in JavaScript | No Comments »

Lots of times, when you use APIs they are using Epoc time to specify a date (which is the number of seconds that have elapsed since midnight (UTC),January 1, 1970). This post isn’t to explain why Epoc is that date, though interesting. Here is some quick JS to convert that to a real human date in your local time zone:

function realDate (epoc){
    var d = new Date();
    d.setTime(epoc * 1000);
    return d;
}

realDate(1354908817);
// returns Fri Dec 07 2012 11:33:37 GMT-0800 (PST)