This file contains 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
[debug] | |
mode=environment | |
output_map_data_info=0 | |
show_load_info=0 | |
show_script_messages=0 | |
show_tile_num=0 | |
[preferences] | |
brightness=1.000000 | |
combat_difficulty=1 |
This file contains 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
/*! | |
* xhrBinary.js | |
* Author: Jared Abbott | |
* Copyright 2015 Jared Abbott | |
* Distributed under the MIT license | |
*/ | |
var xhrBinary = function(url, fn) { | |
// RESOURCES | |
// http://mgran.blogspot.com/2006/08/downloading-binary-streams-with.html |
This file contains 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 __support = { | |
// Blob | |
Blob: !!window.Blob, | |
BlobSlice: !!Blob.prototype.slice, | |
URL: !!window.URL, | |
} | |
var prefixes = ['webkit', 'Webkit', 'WebKit', 'moz', 'Moz', 'o', 'O', 'ms', 'Ms', 'MS', 'khtml', 'Khtml', '']; | |
// Number of prefixes | |
var i = prefixes.length; |
This file contains 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 xhr = new XMLHttpRequest(); | |
xhr.open('GET', url, true); | |
xhr.responseType = 'blob'; | |
xhr.onload = function(e) { | |
if (this.status == 200) { | |
// Return the blob and set the contentType | |
// Note: .response instead of .responseText | |
var _viewBlob = function(data, contentType) { | |
var file = new Blob([data], { | |
type: contentType |
This file contains 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
// Simple BlobBuilder fallback for Blob | |
if(!__support.Blob) { | |
// BlobBuilder fallback for Blob | |
(function(blob) { | |
blob = function(data, obj) { | |
var n; | |
// Fallback for BlobBuilder | |
while ((i -= 1) > -1) { | |
window.BlobBuilder = window.BlobBuilder || window[prefixes[i] + 'BlobBuilder']; |
This file contains 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
// Just before switching jobs: | |
// Add one of these. | |
// Preferably into the same commit where you do a large merge. | |
// | |
// This started as a tweet with a joke of "C++ pro-tip: #define private public", | |
// and then it quickly escalated into more and more evil suggestions. | |
// I've tried to capture interesting suggestions here. | |
// | |
// Contributors: @r2d2rigo, @joeldevahl, @msinilo, @_Humus_, | |
// @YuriyODonnell, @rygorous, @cmuratori, @mike_acton, @grumpygiant, |
This file contains 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
# | |
# ~/.bashrc | |
# | |
# If not running interactively, don't do anything | |
[[ $- != *i* ]] && return | |
alias ls='ls --color=auto' | |
PS1='[\u@\h \W]\$ ' |
This file contains 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
sudo mkdir /mnt/arch && sudo mount /dev/sda5 /mnt/arch && sudo arch-chroot /mnt/arch /usr/bin/mkinitcpio -p linux && cd /mnt/arch && sudo mount -t proc proc proc/ && sudo mount --rbind /sys sys/ && sudo mount --rbind /dev dev/ |
This file contains 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
/** | |
* JSS | |
* Author: Jared Abbott | |
* Copyright 2015 Jared Abbott | |
* Distributed under the MIT license | |
* | |
* @param {Object} | |
*/ | |
var _jss = function(jss, combinator) { | |
var _toString = Function.prototype.call.bind(Object.prototype.toString); |
This file contains 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
/*! | |
* polyfill.insertAdjacentHTML.js | |
* Author: Jared Abbott | |
* Description: A Cross-browser implementation of HTMLElement.insertAdjacentHTML | |
* Copyright 2015 Jared Abbott | |
* Distributed under the MIT license | |
*/ | |
if (!("insertAdjacentHTML" in document.createElementNS("http://www.w3.org/1999/xhtml", "_"))) { | |
HTMLElement.prototype.insertAdjacentHTML = function(position, html) { |