I, rjp, do solemnly offer these my responses to The Road to Ruby Survey:
0. Briefly describe yourself?
Humanoid, halfway through expected lifecycle.
1. When did you first try Ruby seriously?
# -*- coding: utf-8 -*- | |
#!/usr/bin/env python | |
# Coded poorly by Brett Kelly | |
# http://nerdgap.com | |
# @inkedmn | |
# -*- coding: utf-8 -*- | |
import urllib2 | |
import urllib |
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use LWP::Simple; | |
use JSON; | |
use Data::Dumper; | |
sub get_skillz { |
#! /usr/bin/perl | |
use Data::Dumper; | |
use CGI; | |
my $a = new CGI; | |
print $a->header('text/plain'); | |
print Dumper($a); | |
print "XX ", $a->http('Host'), "\n"; | |
print "YY ", $ENV{'HTTP_HOST'}, "\n"; | |
print "ZZ ", $a->http('Authorization'), "\n"; |
boot=$((SECONDS % 20)) | |
time=$(($(date +%s) % 20)) | |
offset=$((20-(time-boot))) | |
echo "boot=$boot time=$time offset=$offset" | |
while [ 1 ]; do | |
while [ $(((SECONDS-offset) % 20)) -lt 18 ]; do sleep 1; done | |
while [ $(((SECONDS-offset) % 20)) -lt 19 ]; do echo >/dev/null; done | |
sleep 1 | |
./snowcam.sh || exit |
#!/usr/bin/env ruby -wKU | |
# Paste this code into a TextExpander snippet to have the Shakespeare Insult Kit a keystroke away | |
# Just set the Content of the TextExpander snippet to 'Shell Script', and give it an abbreviation | |
# Shakespeare Insult Kit: http://www.pangloss.com/seidel/shake_rule.html | |
print "Thou " + ["artless","bawdy","beslubbering","bootless","churlish","cockered","clouted","craven","currish","dankish","dissembling","droning","errant","fawning","fobbing","froward","frothy","gleeking","goatish","gorbellied","impertinent","infectious","jarring","loggerheaded","lumpish","mammering","mangled","mewling","paunchy","pribbling","puking","puny","qualling","rank","reeky","roguish","ruttish","saucy","spleeny","spongy","surly","tottering","unmuzzled","vain","venomed","villainous","warped","wayward","weedy","yeasty","cullionly","fusty","caluminous","wimpled","burly-boned","misbegotten","odiferous","poisonous","fishified","Wart-necked"].shuffle.first + " " + ["base-court","bat-fowling","beef-witted","beetle-hea |
#!/usr/bin/env ruby | |
## disconnect | |
# ./disconnect.rb -u yourusername [-o /your/path] [-p yourhttpproxyserver] | |
# | |
# This is a command-line utility for the bulk-downloading of run data from | |
# the connect.garmin.com web application, which has lackluster export | |
# capabilities. | |
# |
(Hopefully at least one of these questions is useful.)
Figures and stuff taken from my 2012-11-21 notes at the Greenwich TSA meeting. Might be flawed. Please double-check before quoting!
Also please fork, expand, notate, go wild.
#!/usr/bin/env sh | |
## | |
# This is script with usefull tips taken from: | |
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
# | |
# install it: | |
# curl -sL https://raw.github.com/gist/2108403/hack.sh | sh | |
# |
2011/12/05 17:45:03 [debug] 11136#0: epoll: fd:11 ev:0001 d:0853AB1C | |
2011/12/05 17:45:03 [debug] 11136#0: post event 08553AF4 | |
2011/12/05 17:45:03 [debug] 11136#0: timer delta: 7457 | |
2011/12/05 17:45:03 [debug] 11136#0: posted event 08553AF4 | |
2011/12/05 17:45:03 [debug] 11136#0: delete posted event 08553AF4 | |
2011/12/05 17:45:03 [debug] 11136#0: accept on 0.0.0.0:8080, ready: 0 | |
2011/12/05 17:45:03 [debug] 11136#0: posix_memalign: 081A5E70:256 @16 | |
2011/12/05 17:45:03 [debug] 11136#0: *1 accept: 206.251.255.197 fd:17 | |
2011/12/05 17:45:03 [debug] 11136#0: *1 event timer add: 17: 60000:257236343 | |
2011/12/05 17:45:03 [debug] 11136#0: *1 epoll add event: fd:17 op:1 ev:80000001 |