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
// fn to handle jsonp with timeouts and errors | |
// hat tip to Ricardo Tomasi for the timeout logic | |
$.getJSONP = function(s) { | |
s.dataType = 'jsonp'; | |
$.ajax(s); | |
// figure out what the callback fn is | |
var $script = $(document.getElementsByTagName('head')[0].firstChild); | |
var url = $script.attr('src') || ''; | |
var cb = (url.match(/callback=(\w+)/)||[])[1]; |
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
require 'digest/md5' | |
def gfm(text) | |
# Extract pre blocks | |
extractions = {} | |
text.gsub!(%r{<pre>.*?</pre>}m) do |match| | |
md5 = Digest::MD5.hexdigest(match) | |
extractions[md5] = match | |
"{gfm-extraction-#{md5}}" | |
end |
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
The Trouble With Terminals | |
Thu, 16 Dec 2010 16:43:20 -0800 | |
Copyright 2010 Kevin Goodsell | |
0. License | |
This work is licensed under a Creative Commons | |
Attribution-NonCommercial-ShareAlike 3.0 Unported License. To view a |
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
#!/bin/sh | |
# set -x | |
cmd=`php -r "require('$1'); | |
echo escapeshellcmd(sprintf('mysql %s %s %s %s', | |
'-h' . DB_HOST, '-u' . DB_USER, '-p' . DB_PASSWORD, DB_NAME));"` | |
# echo $cmd | |
exec $cmd |
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
<?php | |
// quick and dirty argument parsing | |
foreach ($argv as $arg) { | |
if ($arg == '-f') { | |
define('FOLLOW', true); | |
} | |
if ($arg == '-h') { | |
define('HISTOGRAM', true); | |
} |
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
// Add this code snippet after including jQuery | |
// The if statement protects you in case you forget to remove this | |
// once you upgrade to 1.7, or if you try to use it with jQuery 1.3 | |
if (jQuery.event.props[17] === "layerX" ) { | |
jQuery.event.props.splice(17,2); | |
} |
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
From: Chris DeSalvo <[email protected]> | |
Subject: Why we can't process Emoji anymore | |
Date: Thu, 12 Jan 2012 18:49:20 -0800 | |
Message-Id: <[email protected]> | |
--Apple-Mail=_6DEAA046-886A-4A03-8508-6FD077D18F8B | |
Content-Transfer-Encoding: quoted-printable | |
Content-Type: text/plain; | |
charset=utf-8 |
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
#!/bin/bash | |
# from | |
# http://bergamini.org/computers/creating-favicon.ico-icon-files-with-imagemagick-convert.html | |
convert source-WxW.png -resize 256x256 -transparent white favicon-256.png | |
convert favicon-256.png -resize 16x16 favicon-16.png | |
convert favicon-256.png -resize 32x32 favicon-32.png | |
convert favicon-256.png -resize 64x64 favicon-64.png | |
convert favicon-256.png -resize 128x128 favicon-128.png |
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
# modified API url to align with changes to bit.ly requirements - @claylevering | |
# find the .alfredextension here: http://cl.ly/EEUK | |
declare -r API='https://api-ssl.bitly.com/v3/shorten' | |
declare -r LOGIN='yourlogin' | |
declare -r API_KEY='yourapi' | |
# add http scheme to URL if none is provided | |
longURL=$(printf "{query}" | sed -E -e 's|^.|http://&|' -e 's|^http://([a-zA-Z\-\.\+]+://)|\1|') | |
This file has been truncated, but you can view the full file.
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
The following patch is a combination of the Dell contributions to ipmitool, taken from the following Dell tarball for the corresponding RPM: | |
http://opensource.dell.com/releases/BMU/ipmitool-1.8.11-99.dell.tar.bz2 | |
This patch was generated by diff'ing the upstream ipmitool-1.8.11 source against the ipmitool-1.8.11-99.dell source, with the following command: | |
% diff -urN -x .git -x autom4te.cache -x Makefile -x config.h -x config.log -x config.status -x '*.keep' -x .deps -x '*.spec' ipmitool-1.8.11 ipmitool-1.8.11-99.dell > ipmitool-1.8.11-99.dell.patch | |
Release Notes.txt | 9 | |
ipmitool-1.8.11-99.dell/CHANGES.txt | 8 |
OlderNewer