Skip to content

Instantly share code, notes, and snippets.

@robbielamb
robbielamb / keybase.md
Created August 9, 2016 02:36
keybase.md

Keybase proof

I hereby claim:

  • I am robbielamb on github.
  • I am robbielamb (https://keybase.io/robbielamb) on keybase.
  • I have a public key whose fingerprint is 30BC 46F1 2A8E DC00 F0AC 8B9D 554C C642 F092 9242

To claim this, I am signing this object:

#!/bin/bash
sudo su postgres -c 'cd /opt/local/var/db/postgresql84; /opt/local/lib/postgresql84/bin/pg_ctl -D /opt/local/var/db/postgresql84/defaultdb start'
# Yogo Data Management Toolkit
# Copyright (c) 2010 Montana State University
#
# License -> see license.txt
#
# FILE: persvr.rake
#
#
require 'slash_path'
source 'http://rubygems.org'
RAILS_VERSION = '~> 3.0.0'
DM_VERSION = '~> 1.0.0'
RSPEC_VERSION = '~> 2.0.0.beta.20'
DATAMAPPER = 'git://github.com/datamapper'
gem 'activesupport', RAILS_VERSION, :require => 'active_support'
gem 'actionpack', RAILS_VERSION, :require => 'action_pack'
---
:benchmark: false
:backtrace: false
:update_sources: true
:verbose: true
:bulk_threshold: 1000
:sources:
- http://rubygems.org/
gem: --no-ri --no-rdoc
RED="\[\033[0;31m\]"
YELLOW="\[\033[0;33m\]"
GREEN="\[\033[0;32m\]"
BLUE="\[\033[0;34m\]"
GRAY="\[\033[1;30m\]"
CYAN="\[\033[1;36m\]"
LIGHT_RED="\[\033[1;31m\]"
LIGHT_GREEN="\[\033[1;32m\]"
WHITE="\[\033[1;37m\]"
LIGHT_GRAY="\[\033[0;37m\]"
class FractionalIntegrator
# Positive q is derivation
# Negative q is integration
def initialize(q = 0.5, history_length = 1000)
@q = q
@history = []
@weights = []
initialize_weights(q, history_length)
end
class CustomFormBuilder < ActionView::Helpers::FormBuilder
helpers = field_helpers +
%w(date_select datetime_select time_select collection_select calendar_date_select) +
%w(collection_select select country_select time_zone_select) -
%w(hidden_field label fields_for)
helpers.each do |name|
define_method(name) do |field, *args|
options = args.last.is_a?(Hash) ? args.pop : {}
#!/usr/bin/env ruby -w
require 'net/http'
require 'uri'
require 'rubygems'
require 'json'
require 'ruby-debug'
SERVER = 'localhost'