Skip to content

Instantly share code, notes, and snippets.

@jschank
jschank / # neo4j - 2019-04-01_15-01-05.txt
Created April 1, 2019 20:06
neo4j on macOS 10.14.4 - Homebrew build logs
Homebrew build logs for neo4j on macOS 10.14.4
Build date: 2019-04-01 15:01:05
@jschank
jschank / git config
Last active September 12, 2018 13:02
user.name=John Schank
user.email=jschank@ddcpublicaffairs.com
credential.helper=osxkeychain
core.excludesfile=/Users/jschank/.gitignore_global
core.filemode=true
core.autocrlf=input
core.pager=diff-so-fancy | less --tabs=4 -RFX
core.editor=code -n -w
color.ui=true
color.branch=auto
#! /usr/bin/ruby
fizzy = [1,0,0]
buzzy = [1,0,0,0,0]
1.upto(100) do |i|
fizzy.rotate!
buzzy.rotate!
str = i.to_s * (1 - (fizzy[0] | buzzy[0]))
str << "Fizz" * fizzy[0]
@jschank
jschank / Gemfile
Created October 20, 2012 23:12
gemfile for dewey
source 'http://rubygems.org'
gem 'rails', '3.1.0'
# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'
# gem 'sqlite3'
gem 'pg'
gem 'json'
@jschank
jschank / gist:3889529
Created October 14, 2012 19:12
Text wrapping method
def wrap_text(text, width, indent_width)
raise ArgumentError.new("Width must be at least 1 character wide.") if width <= 1
raise ArgumentError.new("Wrapping width must be greater than the indent amount.") if width <= indent_width
width -= indent_width
lines = []
curline = nil
text.split.each do |word|
#!/bin/sh
mkdir -p /usr/local/src && cd /usr/local/src
wget ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.1-p0.tar.bz2
tar -xjvf ruby-1.9.1-p0.tar.bz2
cd ruby-1.9.1-p0
./configure --prefix=/usr --program-suffix=19 --enable-shared
make && make install