Skip to content

Instantly share code, notes, and snippets.

View hoverbird's full-sized avatar
💭
Neo Cab is out now on Apple Arcade, Steam and Nintendo Switch!

Phenry Ewing hoverbird

💭
Neo Cab is out now on Apple Arcade, Steam and Nintendo Switch!
View GitHub Profile
@sstephenson
sstephenson / test_case.coffee
Created January 10, 2012 19:31
Tiny CoffeeScript testing
#!/usr/bin/env coffee
class TestCase
@run: (print, callback) ->
tests = (new this testName for testName in @getTestNames())
results = []
passed = true
print "1..#{tests.length}"
if (typeof (AC) === "undefined") {
AC = {}
}
AC.ImageReplacer = Class.create({
_defaultOptions: {
listenToSwapView: true,
filenameRegex: /(.*)(\.[a-z]{3}($|#.*|\?.*))/i,
filenameInsert: "_☃x",
ignoreCheck: /(^http:\/\/movies\.apple\.com\/|\/105\/|\/global\/elements\/quicktime\/|_(([2-9]|[1-9][0-9]+)x|nohires)(\.[a-z]{3})($|#.*|\?.*))/i,
attribute: "data-hires",
@marcel
marcel / gist:2100703
Created March 19, 2012 07:24
giftube – Generates an animated gif from a YouTube url.
#!/usr/bin/env ruby
# giftube – Generates an animated gif from a YouTube url.
#
# Usage:
#
# giftube [youtube url] [minute:second] [duration]
#
# ex.
#
@stephencelis
stephencelis / emoji.txt
Created April 3, 2012 18:38
iOS 6 / Mountain Lion Emoji
2139 ℹ INFORMATION SOURCE
23EB ⏫ BLACK UP-POINTING DOUBLE TRIANGLE
23EC ⏬ BLACK DOWN-POINTING DOUBLE TRIANGLE
23F0 ⏰ ALARM CLOCK
23F3 ⏳ HOURGLASS WITH FLOWING SAND
26C5 ⛅ SUN BEHIND CLOUD
26D4 ⛔ NO ENTRY
2705 ✅ WHITE HEAVY CHECK MARK
2753 ❓ BLACK QUESTION MARK ORNAMENT
2757 ❗ HEAVY EXCLAMATION MARK SYMBOL
@darktable
darktable / SavWav.cs
Created April 6, 2012 05:01
Unity3D: script to save an AudioClip as a .wav file.
// Copyright (c) 2012 Calvin Rien
// http://the.darktable.com
//
// This software is provided 'as-is', without any express or implied warranty. In
// no event will the authors be held liable for any damages arising from the use
// of this software.
//
// Permission is granted to anyone to use this software for any purpose,
// including commercial applications, and to alter it and redistribute it freely,
// subject to the following restrictions:
@robinsloan
robinsloan / unbroken-spine-id-notes.txt
Created October 7, 2012 04:39
Unbroken Spine member ID notes
Just a few notes for the curious.
* Every number in Mr. Penumbra's 24-Hour Bookstore is a least a little bit meaningful
* The Unbroken Spine member IDs are extra meaningful
* I checked in the roster and Peter Richardson's member ID is 6K6DV8
* I checked in the roster and Patrick Ewing's member ID is 6L9SN2
* Peter and Patrick had different mentors
* Beware the missing letter
More to come, here and there...
@mstevenson
mstevenson / Fps.cs
Last active November 6, 2025 09:07
An accurate FPS counter for Unity. Works in builds.
using UnityEngine;
using System.Collections;
public class Fps : MonoBehaviour
{
private float count;
private IEnumerator Start()
{
GUI.depth = 2;
✦✧★✩✪✩✫✬ ★✭ ★✧✮✯✪ ✯✩✰✭✯ ✱✲✳✬ ✴✳✵✪ ✧✶ ✩✷✱ ✩✬ ✸✳✵✶✧✹✺✩✱✳✧✵
✬✮✳✷✳✪✭✻ ✧✹ ✬✧✺✭✱✲✳✵✼ ✽✭✹✫ ✬✧✾✲✳✬✱✳✷✩✱✭✪✿ ✰✭✷✩✮✬✭ ✾✭✧✾✯✭ ✩✹✭ ✺✮✷✲ ✺✧✹✭ ✩★✩✹✭ ✧✶ ✱✲✭ ✳✺✾✧✹✱✩✵✷✭ ✧✶ ✧✵✭✬❀ ✳✪✭✵✱✳✱✳✭✬✿ ✰✮✱
✳✵ ✱✲✧✬✭ ✪✩✫✬ ★✭ ✬✳✺✾✯✫ ✷✩✯✯✭✪ ✳✱ ✸❁✭✹✴✱✧✩✬✱✳✵✼✻ ✩✵✪ ✱✲✭✬✭ ✾✭✧✾✯✭ ✧✵ ✱✲✭ ✬✱✩✼✭ ★✭✹✭ ❁✮✬✱ ✩ ✶✭★ ❁✭✹✴✱✧✩✬✱✭✹✬ ★✲✧ ✼✧✱ ✷✩✮✼✲✱❂ ❃✭ ★✭✹✭ ✶✩✬✷✳✵✩✱✭✪ ✰✫ ✱✲✭✺✿ ✰✭✷✩✮✬✭ ✵✧ ✧✵✭ ✧✶ ✮✬ ✲✩✪ ✭✽✭✹ ✱✲✧✮✼✲✱ ✧✶ ✪✭✯✭✱✳✵✼ ✧✮✹✬✭✯✽✭✬❂ ❄✱ ✬✭✭✺✭✪ ✶✮✱✮✹✳✬✱✳✷
✱✧ ✪✧ ✬✧ ✩✵✪ ✳✱ ✬✭✭✺✭✪ ✱✧ ✭❅✲✳✰✳✱ ★✳✯✯✶✮✯ ✩✵✱✳✾✩✱✲✫ ✱✧ ✪✧ ✬✧✿ ★✲✳✷✲✿ ✳✵ ✩ ★✩✫✿ ✬✧✺✭✲✧★ ✬✭✭✺✬ ❆✮✳✱✭ ✶✮✱✮✹✳✬✱✳✷ ✩✬ ★✭✯✯❂ ❇❃✭ ★✭✹✭ ✩✯✯ ✬✧ ★✧✹✹✳✭✪ ✩✰✧✮✱ ✩ ✪✫✬✱✧✾✳✩✵ ✶✮✱✮✹✭ ✩✱ ✱✲✭ ✱✳✺✭✿ ✩
✶✮✱✮✹✭ ✧✶ ✩✬✬✳✺✳✯✩✱✳✧✵ ✧✹ ✩ ✶✮✱✮✹✭ ✧✶ ✬✮✹✽✭✳✯✯✩✵✷✭✿ ✩✵✪ ✱✲✭✬✭ ✾✭✧✾✯✭ ✲✩✪ ✩✬✬✳✺✳✯✩✱✭✪ ✱✲✭✺✬✭✯✽✭✬✿ ✯✧✬✱ ✱✲✭✺✬✭✯✽✭✬✿ ✳✵ ✩ ✬✱✫✯✭
✶✩✹ ✺✧✹✭ ✭✶✶✭✷✱✳✽✭ ✱✲✩✵ ✱✲✭ ✼✧✽✭✹✵✺✭✵✱ ✷✧✮✯✪ ✪✹✭✩✺❂❈ ❉✶ ✷✧✮✹✬✭✿ ❉✾✹✩✲ ★✩✵✱✭✪ ✱✧ ✷✮✱ ✹✳✼✲✱ ✱✧ ✱✲✭ ✰✧✱✱✧✺ ✧✶ ✱✲✳✵✼✬ ✩✵✪ ✬✲✭ ✬✱✹✩✳✼✲✱ ✮✾ ✩✬✴✭✪ ✱✲✭✺✿ ✸❃✲✫ ✪✧ ✱✲✳✬❊ ❃✲✫ ✪✧ ✩✯✯ ✱✲✳✬ ★✧✹✴✿ ✱✲✳✬ ✳✬ ✫✭✩✹✬ ✩✵✪ ✫✭✩✹✬ ✧✶ ★✧✹✴✿ ★✲✫ ✪✧ ✱✲✳✬ ❁✮✬✱ ✱✧
✭✹✩✬✭ ✫✧✮✹✬✭✯✽✭✬ ✶✹✧✺ ✬✧✷✳✭✱✫❊✻
❋✲✭ ✾✭✧✾✯✭ ✳✵ ✱✲✭ ✪✩✹✴ ✬✲✳✶✱✭✪ ✩ ✰✳✱✿
[~/.js] cat github.com.js
// Hashtagify emoji
$(function() {
$('img.emoji').each(function() {
var name = $(this).attr("title").replace(/:/g, '')
if (name == '+1') { name = "thumbsup" }
if (name == '-1') { name = "thumbsdown" }
hashtag = $("<span>#" + name + "</span>");
hashtag.css({ color: '#000', fontWeight: 'bold' });
$(this).replaceWith(hashtag)
@duggi
duggi / Spot the Hijack
Last active February 15, 2018 14:56 — forked from tiffanygwilson/Spot the Hijack
Spot the Hijack
(* Script to record and tag spotify tracks, by Lloyd Moore *)
(* Modified by Tiffany G. Wilson to resolve audio splitting issues, automate starting/stopping, and add recording customization *)
(* Modified by github.com/duggi on 7/18/2014 -- replace slash with dashin new filename to prevent directory write errors *)
(* Snippets for controlling Spotify are from Johnny B on tumblr (http://johnnyb.tumblr.com/post/25716608379/spotify-offline-playlist) *)
(* The idea of using delayed tagging/filename updating is from a guest user on pastebin (http://pastebin.com/rHqY0qg9) *)
(* The only thing to change in the script is the output format; you must change the file extension and the recording format to match *)
(* Run this script once a song you want to record is queued (stopped at beginning) or playing *)
(* Running the script will initiate hijacking, recording and audio playback *)
(* To stop script, pause Spotify or wait for album/playlist to end*)
(* To set id3 tags, use application Kid3 (http://sourceforge.net/pr