Skip to content

Instantly share code, notes, and snippets.

View milcktoast's full-sized avatar
🍂
Making Growth (art game)

Ash Weeks milcktoast

🍂
Making Growth (art game)
View GitHub Profile
@ole
ole / thirty-days-of-metal.md
Last active December 1, 2025 18:57
Warren Moore – Thirty Days of Metal
@qoomon
qoomon / conventional-commits-cheatsheet.md
Last active December 13, 2025 13:43
Conventional Commits Cheatsheet
@nemotoo
nemotoo / .gitattributes
Last active December 2, 2025 14:40
.gitattributes for Unity3D with git-lfs
## Unity ##
*.cs diff=csharp text
*.cginc text
*.shader text
*.mat merge=unityyamlmerge eol=lf
*.anim merge=unityyamlmerge eol=lf
*.unity merge=unityyamlmerge eol=lf
*.prefab merge=unityyamlmerge eol=lf
@mjackson
mjackson / app.js
Created December 29, 2015 05:07
Using webpack with pixi.js
var PIXI = require('pixi.js')
console.log(PIXI)
@annayo
annayo / gist:ead567b083896fc8c29a
Created February 25, 2015 19:36
link-to-custom
Ember.Handlebars.registerBoundHelper('link-to-custom', function () {
var args = [].slice.call(arguments);
var options = args[args.length-1];
var segments = App.Router.router.recognizer.recognize(args.shift().toLowerCase());
if (!segments) { return; }
var max = segments.length - 1;
@milcktoast
milcktoast / blender-upgrade
Last active August 29, 2015 14:03
Blender Upgrade
#! /bin/sh
# usage:
# $ blender-upgrade $version
VERSION=$1
SRC=~/Dropbox/config/blender/
DEST=/Applications/Blender/Blender.app/Contents/Resources/$VERSION/scripts/
cd $SRC;
for d in *

A future version of Ember will come with a new templating engine known as HTMLBars.

The original motivation for HTMLBars was to allow helpers and properties to have better contextual information about what they were bound to.

So for example, consider a template like this:

<a href="{{url}}">{{link}}</a>
@mbostock
mbostock / .block
Last active April 19, 2025 08:19
The Gist to Clone All Gists
license: gpl-3.0
@dalethedeveloper
dalethedeveloper / gist:1503252
Created December 20, 2011 21:00
Mobile Device Detection via User Agent RegEx

#Mobile Device Detection via User Agent RegEx

Yes, it is nearly 2012 and this exercise has been done to death in every imaginable language. For my own purposes I needed to get the majority of non-desktop devices on to a trimmed down, mobile optimized version of a site. I decided to try and chase down an up-to-date RegEx of the simplest thing that could possibly work.

I arrived at my current solution after analyzing 12 months of traffic over 30+ US based entertainment properties (5.8M+ visitors) from Jan - Dec 2011.

The numbers solidified my thoughts on the irrelevancy of including browsers/OSes such as Nokia, Samsung, Maemo, Symbian, Ipaq, Avant, Zino, Bolt, Iris, etc. The brass tacks of the matter is that you certainly could support these obscure beasts, but are you really going to test your site on them? Heck, could you even find one?! Unless the folks that pay you are die hard Treo users my guess is "No".

Interestingly enough my research shows that /Mobile/ is more efficient than **/iP(

@ijy
ijy / Compass px to em
Created December 7, 2011 08:18
A Compass function to convert pixel font-sizes to em's
@function em($target, $context: $base-font-size) {
@if $target == 0 { @return 0 }
@return $target / $context + 0em;
}
$base-font-size: 15px;
h1 {
font-size: em(21px, 15px); // Outputs 1.4em
}