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
#! /bin/bash | |
## | |
# returns the version of the OSX application that's passed to the script | |
# can determine if you're passing a bundle or an application (.bundle | .app | .component) | |
# and figure out the proper info | |
# | |
# written by Spike Grobstein | |
# [email protected] | |
# 2010/11/02 |
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
#! /bin/bash | |
## | |
# spit out random password. default length of 32 characters | |
# usage: | |
# ./random_pw <pw_length> | |
## | |
COUNT=$1 | |
DEFAULT_COUNT=32 |
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
# usage: | |
# netstat -I bond0 -w 1 -b | ruby throughput.rb | |
# shows throughput on selected interface (OSX only) | |
def parse_line(line) | |
column_titles = [ :packets_in, :errs_in, :bytes_in, :packets_out, :errs_out, :bytes_out, :colls ] | |
columns = line.split(/\s+/) | |
columns.shift | |
columns = columns.collect { |c| c.to_i } | |
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
+[,+[-[>+>+<<-]>[<+>-]+>>++++++++[<-------->-]<-[<[-]>>>+[<+<+>>-]<[>+<-]<[<++> | |
>>+[<+<->>-]<[>+<-]]>[<]<]>>[-]<<<[[-]<[>>+>+<<<-]>>[<<+>>-]>>++++++++[<------- | |
->-]<->>++++[<++++++++>-]<-<[>>>+<<[>+>[-]<<-]>[<+>-]>[<<<<<+>>>>++++[<++++++++ | |
>-]>-]<<-<-]>[<<<<[-]>>>>[<<<<->>>>-]]<<++++[<<++++++++>>-]<<-[>>+>+<<<-]>>[<<+ | |
>>-]+>>+++++[<----->-]<-[<[-]>>>+[<+<->>-]<[>+<-]<[<++>>>+[<+<+>>-]<[>+<-]]>[<] | |
<]>>[-]<<<[[-]<<[>>+>+<<<-]>>[<<+>>-]+>------------[<[-]>>>+[<+<->>-]<[>+<-]<[< | |
++>>>+[<+<+>>-]<[>+<-]]>[<]<]>>[-]<<<<<------------->>[[-]+++++[<<+++++>>-]<<+> | |
>]<[>++++[<<++++++++>>-]<-]>]<[-]++++++++[<++++++++>-]<+>]<.[-]+>>+<]>[[-]<]<] | |
!input goes here |
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
<?php | |
//Use this to tunnel a file through json for crossdomain access. | |
try { | |
$uri = $_GET['uri']; // the URI that we're fetching | |
$callback = $_GET['_callback']; // the callback that's used with jsonp (optional) | |
if (is_null($_GET['uri'])) { | |
throw new Exception('Bad URI'); |
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
function uri_to_absolute(server_name, uri) { | |
if (uri.match(/^#/)) { | |
return uri; | |
} | |
var m = server_name.match(/^((.+?\/\/[^\/]+)(.*))/); | |
var server_name = (m) ? m[2] : server_name; | |
var path = (m) ? m[3] : ''; | |
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
javascript:%20var%20x%20=%20$(%22div.content%20div.entry%20a.title%22).each(function()%20{var%20href%20=%20$(this).attr(%22href%22);var%20title%20=%20$(this).text().toLowerCase();if%20(title.indexOf(%27[m]%27)%20>=%200%20&&%20title.indexOf(%27[f]%27)%20<%200)%20{%20return;%20}if%20((!$(this).hasClass(%22drowsapMorphed%22))%20&&%20($(this).next(%22.drowsapMorphed%22).length%20==%200)%20&&%20href%20&&%20(href.indexOf(%27imgur%27)%20>=%200%20||%20href.indexOf(%27jpeg%27)%20>=%200%20||%20href.indexOf(%27jpg%27)%20>=%200%20||%20href.indexOf(%27png%27)%20>=%200))%20{var%20ext%20=%20(href.indexOf(%27imgur%27)%20>=%200%20&&%20href.indexOf(%27jpg%27)%20<%200%20&&%20href.indexOf(%27png%27)%20<%200)%20?%20%27.jpg%27:%20%27%27;var%20img%20=%20$(%22<a%20class=%27drowsapMorphed%27%20href=%27%22%20+%20href%20+%20%22%27%20target=%27blank%27%20style=%27display:block%27><img%20style=%27display:block;max-width:780px;%27%20src=%27%22%20+%20href%20+%20ext%20+%20%22%27%20/></a>%22);$(this).after(img);}}); |
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
function build_static() { | |
var Frontrunner = (function(){ | |
var FR = null; | |
var name = "spike"; | |
return { | |
init: function() { | |
FR = this; | |
return this; | |
}, |
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
#include <stdio.h> | |
#include <unistd.h> | |
#include <stdlib.h> | |
#define DEFAULT_PROCESS_COUNT 4 | |
int process_count = DEFAULT_PROCESS_COUNT; | |
void do_work(int pid); |
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
#!/bin/sh | |
# | |
# pgpool - the postgres replication daemon. | |
# | |
# chkconfig: 2345 64 36 | |
# description: start and stop the pgpool daemon | |
### BEGIN INIT INFO | |
# Provides: pgpool |
OlderNewer