Skip to content

Instantly share code, notes, and snippets.

View olly's full-sized avatar

Oliver Legg olly

View GitHub Profile
@olly
olly / gist:4268927
Created December 12, 2012 15:56
rvm install --debug 2.0.0
2.0.0 - install
Remote file does not exist https://rvm.io/binaries/osx/10.8/x86_64/ruby-2.0.0-preview2.tar.bz2
Remote file does not exist http://jruby.org.s3.amazonaws.com/downloads/ruby-2.0.0-preview2.tar.bz2
rvm_remote_server_url2 not found
No remote file name found
No binary rubies available for: osx/10.8/x86_64/ruby-2.0.0-preview2.
Continuing with compilation. Please read 'rvm mount' to get more information on binary rubies.
Libyaml already installed
rvm_configure_flags+=( --with-opt-dir=/Users/Olly/.rvm/usr )
found compiler: /usr/local/bin/gcc-4.2
[2012-12-12 15:35:53] ./Configure darwin64-x86_64-cc -I/Users/Olly/.rvm/usr/include -L/Users/Olly/.rvm/usr/lib zlib no-asm no-krb5 shared --prefix=/Users/Olly/.rvm/usr --with-opt-dir=/Users/Olly/.rvm/usr
Usage: Configure [no-<cipher> ...] [enable-<cipher> ...] [experimental-<cipher> ...] [-Dxxx] [-lxxx] [-Lxxx] [-fxxx] [-Kxxx] [no-hw-xxx|no-hw] [[no-]threads] [[no-]shared] [[no-]zlib|zlib-dynamic] [no-asm] [no-dso] [no-krb5] [sctp] [386] [--prefix=DIR] [--openssldir=OPENSSLDIR] [--with-xxx[=vvv]] [--test-sanity] os/compiler[:flags]
@olly
olly / csv_progress_bar.rb
Last active October 3, 2019 19:44
Progress Bars for Ruby's CSV
require 'csv'
# https://rubygems.org/gems/progress_bar
require 'progress_bar'
class CSV
module ProgressBar
def progress_bar
::ProgressBar.new(@io.size, :bar, :percentage, :elapsed, :eta)
end
OpenSSH_5.6p1, OpenSSL 0.9.8r 8 Feb 2011
debug1: Reading configuration data /Users/Olly/.ssh/config
debug1: Applying options for *
debug1: Reading configuration data /etc/ssh_config
debug1: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to ec2-46-51-151-203.eu-west-1.compute.amazonaws.com [46.51.151.203] port 22.
debug1: Connection established.
debug2: key_type_from_name: unknown key type '-----BEGIN'
debug2: key_type_from_name: unknown key type 'Proc-Type:'
@olly
olly / dmesg.boot
Created June 5, 2012 12:31
/var/run/dmesg.boot
pci6: <ACPI PCI bus> on pcib6
ehci1: <EHCI (generic) USB 2.0 controller> mem 0xfe502000-0xfe5023ff irq 23 at device 29.0 on pci0
ehci1: [ITHREAD]
usbus1: EHCI version 1.0
usbus1: <EHCI (generic) USB 2.0 controller> on ehci1
isab0: <PCI-ISA bridge> at device 31.0 on pci0
isa0: <ISA bus> on isab0
atapci0: <Intel Cougar Point SATA300 controller> port 0xf0b0-0xf0b7,0xf0a0-0xf0a3,0xf090-0xf097,0xf080-0xf083,0xf060-0xf07f mem 0xfe501000-0xfe5017ff irq 20 at device 31.2 on pci0
atapci0: [ITHREAD]
atapci0: AHCI called from vendor specific driver
@olly
olly / olly.theme
Created November 15, 2011 10:52
My ZSH Theme
# ------------------------------------------------------------------------------
# FILE: olly.zsh-theme
# DESCRIPTION: oh-my-zsh theme file.
# AUTHOR: Olly Legg ([email protected])
# ------------------------------------------------------------------------------
if [[ "$TERM" != "dumb" ]] && [[ "$DISABLE_LS_COLORS" != "true" ]]; then
if [ "$SSH_CONNECTION" ]; then
HOSTNAME="%{$fg_bold[red]%}%n@%m %{$reset_color%}"
require 'set'
require 'matrix'
class OllyPlayer
BoardSize = 10
Infinity = (1.0/0)
class Board
def initialize(current_state, ships_remaining)
row = Array.new(BoardSize, 0)
[info] [<0.125.0>] 127.0.0.1 - - 'GET' /versioned-projects-development/ping 404
[info] [<0.138.0>] 127.0.0.1 - - 'GET' /_uuids?count=1000 200
[info] [<0.163.0>] 127.0.0.1 - - 'PUT' /versioned-projects-development/d6b1b8c10fc3a5ccd602c74eeb1ea9e6 201
[error] [<0.140.0>] ** Generic server <0.140.0> terminating
** Last message in was {pread_iolist,87833962}
** When Server state == {file,{file_descriptor,prim_file,{#Port<0.2101>,13}},
87811362,87834182}
** Reason for termination ==
** {{badmatch,{ok,<<50,84,49,48,58,51,55,58,51,51,90,104,2,109,0,0,0,10,117,
112,100,97,116,101,100,95,97,116,109,0,0,0,20,50,48,49,
Jan 12 15:01:48 lb02 kernel: [88879.477199] Free swap = 917496kB
Jan 12 15:01:48 lb02 kernel: [88879.477201] Total swap = 917496kB
Jan 12 15:01:48 lb02 kernel: [88879.481930] 447488 pages RAM
Jan 12 15:01:48 lb02 kernel: [88879.481933] 263682 pages HighMem
Jan 12 15:01:48 lb02 kernel: [88879.481935] 10460 pages reserved
Jan 12 15:01:48 lb02 kernel: [88879.481936] 11249 pages shared
Jan 12 15:01:48 lb02 kernel: [88879.481937] 329651 pages non-shared
Jan 12 15:01:48 lb02 kernel: [88879.502144] rsyslogd invoked oom-killer: gfp_mask=0xd0, order=1, oom_adj=0
Jan 12 15:01:48 lb02 kernel: [88879.502149] rsyslogd cpuset=/ mems_allowed=0
Jan 12 15:01:48 lb02 kernel: [88879.502153] Pid: 23973, comm: rsyslogd Not tainted 2.6.32-309-ec2 #18-Ubuntu
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>JSON Test</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.3/jquery.min.js"></script>
<script>