Skip to content

Instantly share code, notes, and snippets.

View hongymagic's full-sized avatar
🤪

David Hong hongymagic

🤪
View GitHub Profile
@hongymagic
hongymagic / dabblet.css
Created March 9, 2012 03:27
Gems gems gems gems gems gems gems
/**
* Gems gems gems gems gems gems gems
*/
.gem { display: block; padding-left: 90px; line-height: 80px; font-size: 70px; font-family: Helvetica, Arial, sans-serif; }
.gem.gem-green { background: transparent url(http://images4.wikia.nocookie.net/__cb20100522145657/ztreasureisle/images/7/75/Green_Gem-icon.png) top left no-repeat; }
.gem.gem-red { background: transparent url(http://images4.wikia.nocookie.net/__cb20100522145543/ztreasureisle/images/a/af/Red_Gem-icon.png) top left no-repeat; }
@hongymagic
hongymagic / say [a-zA-Z].sh
Created March 12, 2012 03:11
Generate wav files of Mac voices spelling out the alphabet
#!/bin/zsh
local IFS=$'\n'
for voice in `say -v '?' | cut -c1-20 | sed 's/ *$//g' | tr '[A-Z]' '[a-z]'`
do
for alphabet in `perl -le 'do { print $_ } foreach (a..z);'`
do
if [ ! -d ${voice} ]
then
@hongymagic
hongymagic / README.md
Created March 12, 2012 23:57
Simple zsh wrapper to launch iA Writer from the terminal

This is a simple script to launch iA Writer from the terminal. It is extremely useful for interacting with Github's own wiki system as it provides git access.

INSTALL

One-liner

curl -L https://raw.github.com/gist/2025540/4f3f094286468db2588f40345e6faaf07bd5af2a/ia > /usr/local/bin/ia && chmod u+x /usr/local/bin/ia

Manual, safer way

@hongymagic
hongymagic / sessions.json
Created March 27, 2012 02:50
Go-no-go configuration data
{
"id": 1024,
"name": "Midsomer Murders",
"engine": "Go-No-Go",
"description": "Exercise your working memory",
"assets": {
"screen": {
"background-image": "http://placehold.it/800x600"
@hongymagic
hongymagic / dabblet.css
Created April 3, 2012 22:52
ABC Brain Fit Login box
/**
* ABC Brain Fit Login box
*/
h1, h2, h3, h4, h4, p { margin: 0; padding: 0; }
html, body {
background: #004164;
background: linear-gradient(top, #003f61, #004164);
@hongymagic
hongymagic / dabblet.css
Created April 3, 2012 23:53
ABC Brain Fit Login box
/**
* ABC Brain Fit Login box
*/
h1, h2, h3, h4, h4, p { margin: 0; padding: 0; }
html, body {
background: #004164;
background: linear-gradient(top, #003f61, #004164);
@hongymagic
hongymagic / game.state.js
Created April 11, 2012 07:17
Sample game state management
var GameState = function (ctx) {
this.ctx = ctx;
};
GameState.prototype = {
init: function (timestamp) {
this.start = timestamp;
},
draw: function (timestamp) {
@hongymagic
hongymagic / store.json
Created April 11, 2012 07:59
hon.gy URLs
{
"GzUiYC": "http://greenbytes.de/tech/tc/httplink/",
"OYhntj": "http://documentcloud.github.com/backbone/#Model-save",
"aMJFI5": "http://twitter.com/hongymagic",
"4irhw5": "http://iphone.news.com.au/",
"kony2012": "http://kony2012.com/",
"s8Ad9c": "https://gist.github.com/1532562",
"0d9oZX": "http://www.codinghorror.com/blog/2007/02/why-cant-programmers-program.html#comments",
"KTGqtO": "http://hyperpolyglot.org/scripting",
"tqG8pm": "http://jsbin.com/itiqop/3/edit#javascript,live",
@hongymagic
hongymagic / dabblet.css
Created April 12, 2012 01:56
Game icon
/**
* Game icon
*/
.game {
display: block;
margin: 0; padding: 0;
width: 100px; height: 100px;
position: relative;
@hongymagic
hongymagic / dabblet.css
Created April 12, 2012 01:57
Game icon for ABC Brainfit
/**
* Game icon for ABC Brainfit
*/
.game,.game.locked::after,.game h4 {
display:block;
margin:0;
box-sizing:border-box
}