The default installer that comes with Laravel is great, but unfortunately that means you have to install dependencies of PHP and Laravel/Lumen first, before you can get started working on your application. This is not longer the case, so long as you use Docker. And you should.

All you need to do is:


docker run -v `pwd`:/var/www alairock/laravel 'laravel new site-name'


docker run -v `pwd`:/var/www alairock/lumen 'laravel new service-name'

Bonus Round!

These containers aren’t just good for installing laravel apps. You can also use them for development. (Remember, you need to add --host= in order to make sure that external connections to the artisan server are allowed)

$ cd site-name # or service-name if using lumen
$ docker run -v `pwd`:/var/www -p "8080:8000" alairock/lumen 'php artisan serve --host='

Just don’t forget to link to your database, nginx, or whatever other containers you are needing to integrate with.

Lessons learned going from PHP to Python.


While Python does have and use classes, it’s not always required to use them. You can think of files as classes in most cases.


def meow():
	print "meow"


import cat


Although, if you want to use classes you can. There are some interesting differences to remember.

class Cat: # Class names are StudlyCased
	def purr(self): #functions are typically lowercase, need self  if you aren't passing params
		print "purr"

var kitten = Cat() # To instantiate use parens () "new" is not a thing in python

What is self? Check out this answer here

What about construction?


	class Kitten() {
		public function __construct() {}


class Kitten:
		# construction stuff here



switch ($i) {
	case 0:
		echo "i equals 0";
	case 1:
		echo "i equals 1";
		echo "default";


i = 1
if (i == 0):
	print "One"
elif (i == 1):
	print "Two"
	print "default"

Notice in Python it’s just an if-elseif-else statement. In Python there is no switch statement. A switch is just shorthand for conditionals, so it’s not a huge loss if you really think about it.


This article is a work in progress. More to come. If you notice any issues or typos, please leave it in the comments and I will happily fix it.

Just upgraded to a 2015 Macbook Pro and one of the primary hardware update is the trackpad. The trackpad is not a physical button, like previous models, but static, and has force tracking technology underneath.

This hasn’t really changed the experience for me day-to-day but I did find a really cool trick with it while playing with a Midi Python library. When you open Logic and open up the virtual keyboard, you can use your keyboard or mouse to activate a note and play a sound. With the new trackpad, it adds another element to this keyboard, aftertouch.

Aftertouch is after the note has been turned on, but before it has been turned off. In midi, this can be used to control things like vibrato, volume, pitch, and any combination of things. Logic has integrated the force sensor of the trackpad into the virtual keyboard, allowing you to incorporate aftertouch activities in the software. Pretty neat, if you ask me.

location ^~ /blog {
    proxy_set_header Host $http_host;
    proxy_set_header X-NginX-Proxy true;
    proxy_redirect off;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    server_name_in_redirect off;
    port_in_redirect off;

Laravel Cashier lets you have these fancy-shmancy PDF downloads of invoices.

This is awesome, except it seems that in some cases the permissions are not correct... or fall out of correctness. Chmod'ing will fix this. (Link no longer working since Taylor took down the issues  *sheds tear*)

cd [app_path]/vendor/laravel/cashier/src/Laravel/Cashier/bin/linux-x86_64
chmod a+x phantomjs

Note: That path above may not necessarily be in linux-x86_64 as it will depend on your system. Be sure to verify which system you are running and update this path accordingly.

I just updated SourceTree, and what did I find? They updated their logo! But the funny thing about it is their striking similarity to the icon I designed in March, 6 months before they released theirs.


Their icon in March

My icon designed in March
SourceTree Desktop Icon

Their icon, released yesterday



The similarity is striking. But alas, I don't care. It's just cool to see I was on the right path. :)

(Also, as of writing this post, if you did a google search for "sourcetree app icon", my icon is the first or second result)

After doing the Atom Editor Desktop Icon, I kinda felt that the source tree one was pretty out dated as well. I flattened it up.

SourceTree Desktop Icon


You can download it HERE.

Atom Editor is a brand new code editor still in beta, and my first reaction is 'Awesome!'.

As much as I love the fact that it is built on JS/CoffeeScript and (basically) chrome, I can't get over how nasty their icon is, so I made my own.

Atom Editor Desktop Icon


And in spirit of OpenSource I am giving away the icon for free. Click HERE to download.

If you want the vector version however, I am looking for a Dribbble invite, and would be happy to trade an invite for the vector.