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 'formula' | |
class Hadoop < Formula | |
url 'http://www.apache.org/dyn/closer.cgi?path=hadoop/core/hadoop-0.20.204.0/hadoop-0.20.204.0.tar.gz' | |
homepage 'http://hadoop.apache.org/common/' | |
md5 'ea9a0699405074f169dccd3cc6adb608' | |
def shim_script target | |
<<-EOS.undent | |
#!/bin/bash |
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
if ENV.include?('RAILS_ENV') && !Object.const_defined?('RAILS_DEFAULT_LOGGER') | |
require 'logger' | |
RAILS_DEFAULT_LOGGER = Logger.new(STDOUT) | |
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
<?xml version='1.0'?> | |
<!DOCTYPE service_bundle SYSTEM '/usr/share/lib/xml/dtd/service_bundle.dtd.1'> | |
<service_bundle type='manifest' name='export'> | |
<service name='application/atlassian/jira' type='service' version='0'> | |
<dependency name='network' grouping='require_all' restart_on='none' type='service'> | |
<service_fmri value='svc:/milestone/network:default'/> | |
</dependency> |
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
nmap <SwipeUp> :split<CR> | |
nmap <SwipeDown> :split<CR><C-w>j<CR> | |
nmap <SwipeLeft> <C-w>v<CR> | |
nmap <SwipeRight> <C-w>v<CR><C-w>l<CR> |
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/ksh | |
# Public domain. Use as you wish. | |
EMAIL=admins@darkstar | |
TMPFILE=/tmp/fmadm.output.$$ | |
export PATH=/usr/bin:/usr/sbin | |
# |
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
int | |
main(int argc, char *argv[]) | |
{ | |
dispatch_async(dispatch_get_global_queue(0, 0), ^{ | |
EditLine *el; | |
History *myhistory; | |
int count; | |
const char *line; | |
HistEvent ev; |
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
#define foreach(LIST, FUN) \ | |
{ \ | |
list_t *__i = LIST; \ | |
while (__i != NULL) { \ | |
FUN(__i->node); \ | |
__i = __i->next; \ | |
} \ | |
} while(0) | |
foreach(world->hexes, ^(hex_t *hex) { |
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
module LocationFinder | |
class FindMyIphone | |
def self.find(username, password) | |
agent = Mechanize.new | |
login_page = agent.get('https://auth.me.com/authenticate?service=findmyiphone&ssoNamespace=appleid') | |
login_form = login_page.forms.first | |
login_form.username = username | |
login_form.password = password | |
agent.submit(login_form, login_form.buttons.first) |
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
bool | |
is_prime(int num) | |
{ | |
int i, w; | |
if (num <= 1) | |
return false; | |
if (num == 2 || num == 3) | |
return true; |