This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| --- | |
| name : Animation | |
| provides : Animation | |
| description : | | |
| Simple animation implementation | |
| uses CSS Animation where available | |
| uses MooTools' Fx for other browsers | |
| authors : Valerio Proietti (http://mad4milk.net) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # author: Thomas Aylott SubtleGradient.com | |
| echo "Transmitting" | |
| for i in `git log -${1:-1} $2 --name-only|grep -E '^[^ ]+$'|sort|uniq`; do | |
| if [[ -e $i ]]; then | |
| echo " $i" | |
| open -a Transmit $i | |
| fi | |
| done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| echo "Transmitting" | |
| for i in `git log -${1:-1} --name-only|grep -E '^[^ ]+$'|sort|uniq`; do | |
| if [[ -e $i ]]; then | |
| echo " $i" | |
| open -a Transmit $i | |
| fi | |
| done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var iterations = 999999, control = '', eq_same = '', seq_same = '', eq_diff = '', seq_diff = '', st, en; | |
| setTimeout(function(){ | |
| st = +new Date(); | |
| for (i = 0; i < iterations; i++); | |
| en = +new Date(); | |
| control = en - st; | |
| print(); | |
| },100); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Swap classes onload and domready | |
| $(function(){ $('html').removeClass('not-ready').addClass('ready'); }); // jQuery | |
| $(window).load(function(){ $('html').removeClass('loading').addClass('loaded'); }); | |
| // target a specific version | |
| if (navigator.isIE == 6){ | |
| // do stuff for IE6 | |
| } | |
| // Deliever different behaviour for a group of IE versions |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Person = Class.subclass(function(def, Protected, Generic, Parent){ | |
| // Private | |
| // Available to all methods in this definition | |
| var private_variable; | |
| // Protected | |
| // Available to this Class, its instances, all subclasses and all their instances | |
| // Protected methods are bound to each instance |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Array.append(array,array2) // MooTools 1.3wip | |
| Array.clean(array) // MooTools 1.3wip | |
| Array.combine(array,array2) // MooTools 1.3wip | |
| Array.concat(array[,item1[,item2[,...]]]) // JavaScript 1.6 | |
| Array.contains(array,item[,from]) // MooTools 1.3wip | |
| Array.empty(array) // MooTools 1.3wip | |
| Array.erase(array,item) // MooTools 1.3wip | |
| Array.every(array,callback[,thisObject]) // JavaScript 1.6 | |
| Array.every(array,fn[,bind]) // MooTools 1.3wip | |
| Array.filter(array,callback[,thisObject]) // JavaScript 1.6 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
| <plist version="1.0"> | |
| <dict> | |
| <key>bundleUUID</key> | |
| <string>4A3012B7-3A3F-4B2A-871C-2E6266BC0A21</string> | |
| <key>fileTypes</key> | |
| <array> | |
| <string>html</string> | |
| <string>htm</string> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| --- | |
| source : http://gist.github.com/gists/311328 | |
| provides : getArg | |
| description : Get an array of arguments with accessing `arguments` | |
| version : Rough proof-of-concept | |
| author : Thomas Aylott | |
| site : SubtleGradient.com |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Do some more of the same sort of stuff with another DB search | |
| // Bind the DB to the UI | |
| MyDBDSL("#big") | |
| .change(function(){ | |
| var rows = MyDBDSL(this).rows(); | |
| jQuery("#products #big").removeClass('db-error') | |
| .find("form .db-invalid").removeClass('db-invalid').end() | |
| .find("table").html( rows.html() ); | |
| }) |