Skip to content

Instantly share code, notes, and snippets.

View earlcochran's full-sized avatar

Earl Cochran earlcochran

  • New Orleans, LA
View GitHub Profile
@earlcochran
earlcochran / surf_network_2009_njv.cfg
Last active March 2, 2016 17:56
A Stripper:Source configuration file for surf_network_2009_njv. It removes the doors in the beginning of the map, the abyss jail, and the weapon stripping.
filter:
{
"model" "*37"
"targetname" "blast_doors1"
"noise2" "doors/drawbridge_stop1.wav"
"noise1" "doors/drawbridge_move1.wav"
"origin" "20.25 1040 235.75"
"spawnflags" "0"
"movedir" "45 0 90"
"loopmovesound" "0"
@earlcochran
earlcochran / surf_coralis_ksf-.cfg
Last active March 2, 2016 17:28
Stripper:Source configuration file for surf_coralis_ksf-
filter:
{
"origin" "-12083.9 -12192 10002"
"classname" "trigger_teleport"
}
{
"origin" "-343 -2477 4255"
"classname" "trigger_teleport"
}
/**
* vim: set ts=4 :
* =============================================================================
* SourceMod Rock The Vote Plugin
* Creates a map vote when the required number of players have requested one.
*
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
* =============================================================================
*
* This program is free software; you can redistribute it and/or modify it under

Keybase proof

I hereby claim:

  • I am earlcochran on github.
  • I am efco (https://keybase.io/efco) on keybase.
  • I have a public key whose fingerprint is 011D 67F2 D2DE 04FA BBD5 E7F8 E161 9392 1773 AB04

To claim this, I am signing this object:

@earlcochran
earlcochran / reddit-mass-unsubscribe.js
Created June 24, 2015 14:15
Reddit Mass Unsubscribe
x = $('.sidecontentbox').find('.remove');
i = 0;
theInterval = setInterval(function(){
if (i === x.length + 1) {
clearInterval(theInterval)
} else {
$(x[i]).click()
i++
}
}, 2000)
@earlcochran
earlcochran / flac2mp3
Last active August 29, 2015 14:08
Convert FLAC files to LAME V0 mp3's
if [ ! -d "mp3" ]; then
mkdir mp3
fi
for f in *.flac; do
for tag in TITLE ARTIST ALBUM DATE COMMENT TRACKNUMBER TRACKTOTAL GENRE; do
eval "$tag=\"`metaflac --show-tag=$tag "$f" | sed 's/.*=//'`\""
done
@earlcochran
earlcochran / jquery.containsExact.js
Last active December 21, 2015 17:39
jQuery :containsExact() selector
/**
* All credit goes to http://wowmotty.blogspot.com/2010/05/jquery-selectors-adding-contains-exact.html
*/
$.extend( $.expr[":"], {
containsExact: $.expr.createPseudo ?
$.expr.createPseudo(function(text) {
return function(elem) {
return $.trim(elem.innerHTML.toLowerCase()) === text.toLowerCase();
};
/*--- waitForKeyElements(): A utility function, for Greasemonkey scripts,
that detects and handles AJAXed content.
Usage example:
waitForKeyElements (
"div.comments"
, commentCallbackFunction
);