$ ./githubapi-get.sh $GITHUBTOKEN /users/mbohun/reposHTTP/1.1 200 OK
Server: GitHub.com
Date: Wed, 04 Mar 2015 04:30:29 GMT
Content-Type: application/json; charset=utf-8
Content-Length: 155683
Status: 200 OK$ ./githubapi-get.sh $GITHUBTOKEN /users/mbohun/reposHTTP/1.1 200 OK
Server: GitHub.com
Date: Wed, 04 Mar 2015 04:30:29 GMT
Content-Type: application/json; charset=utf-8
Content-Length: 155683
Status: 200 OKDouglas Crockford, author of JavaScript: The Good parts, recently gave a talk called The Better Parts, where he demonstrates how he creates objects in JavaScript nowadays. He doesn't call his approach anything, but I will refer to it as Crockford Classless.
Crockford Classless is completely free of class, new, this, prototype and even Crockfords own invention Object.create.
I think it's really, really sleek, and this is what it looks like:
function dog(spec) {Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
| #!/bin/bash | |
| # A little Bash script to make a mirror of your Github repositories and keep | |
| # them up-to-date. | |
| # Why mirroring? Because I can! | |
| # Also, it will be very useful if one day a meteorite crashes into Github | |
| # servers (even if it will not happen). | |
| # https://gist.github.com/950441 |