Skip to content

Instantly share code, notes, and snippets.

View lmarburger's full-sized avatar
🥖
Temporally nondeterministic

Larry Marburger lmarburger

🥖
Temporally nondeterministic
View GitHub Profile
@lmarburger
lmarburger / mullions.md
Created February 7, 2018 13:59
My HoA's struggle with window mullions and the homeowner who dared remove them.

February 18, 2016

  • A carriage homeowner communicated with the Board via telephone regarding a request to remove the mullions from windows in his home.

September 15, 2016

  • The Board discussed the Attorney response regarding a Carriage Homeowner who has removed the mullions from his windows. The Association has asked that these be reinstalled, as they are an exterior component of the home. The letter from the Association attorney was approved as written.

October 20, 2016

Keybase proof

I hereby claim:

  • I am lmarburger on github.
  • I am lmarburger (https://keybase.io/lmarburger) on keybase.
  • I have a public key ASAzuj9vsNwjbTdCxRO3iiYpAgGtgB8JUmbJLHA9-jNIOQo

To claim this, I am signing this object:

@lmarburger
lmarburger / 1-work.rb
Last active May 25, 2020 11:40
Quit and suspend a ruby process for debugging
require 'bundler/setup'
require 'rbtrace'
require 'English'
$run = true
Signal.trap('HUP') { $run = false }
while $run do
puts "pid=#{$PID} time=#{Time.now}"
sleep 10
@lmarburger
lmarburger / synth.ino
Last active February 18, 2020 18:55
// Auduino, the Lo-Fi granular synthesiser
//
// by Peter Knight, Tinker.it http://tinker.it
//
// Help: http://code.google.com/p/tinkerit/wiki/Auduino
// More help: http://groups.google.com/group/auduino
//
// Analog in 0: Grain 1 pitch
// Analog in 1: Grain 2 decay
// Analog in 2: Grain 1 decay
# Works fine
loop do
before_gc = ObjectSpace.each_object(Thread).count
GC.start
after_gc = ObjectSpace.each_object(Thread).to_a # <-- note #to_a in loop
$stdout.print "before_gc=#{before_gc} after_gc=#{after_gc.count}\n"
sleep 1
end
@lmarburger
lmarburger / runtime_instrumentation.rb
Created January 29, 2016 16:36
Measure ruby vm variance
require 'hitimes'
require 'librato/metrics'
require 'thread'
class RuntimeInstrumentation
def self.queue
@queue ||= Librato::Metrics::Queue
.new(source: ENV.fetch('SOURCE_NAME'),
autosubmit_interval: ENV.fetch('METRIC_SUBMIT_INTERVAL', 10).to_i)
end
https://github.com/rails/rails/blob/2-3-stable/activesupport/lib/active_support/values/time_zone.rb#L26-L170
https://github.com/rails/rails/blob/3-2-stable/activesupport/lib/active_support/values/time_zone.rb#L28-L173
$ diff rails2.3 rails3.2
3c3
< "Samoa" => "Pacific/Pago_Pago"
---
> "American Samoa" => "Pacific/Pago_Pago"
30c30
< "Georgetown" => "America/Argentina/San_Juan"
@lmarburger
lmarburger / gol.idr
Created October 13, 2014 20:41
Game of Life in Idris
module GoL
%default total
data Cell = Alive | Dead
Board : Type
Board = Vect 3 (Vect 3 Cell)
nextCellState : Cell -> Nat -> Cell
@lmarburger
lmarburger / output
Created October 3, 2014 18:03
Playing with state effects in Idris
$ idris state.idr -p effects
____ __ _
/ _/___/ /____(_)____
/ // __ / ___/ / ___/ Version 0.9.14.3
_/ // /_/ / / / (__ ) http://www.idris-lang.org/
/___/\__,_/_/ /_/____/ Type :? for help
Idris is free software with ABSOLUTELY NO WARRANTY.
For details type :warranty.
*state> testAdd 1
#!/bin/sh
# Pomodoro timer
osascript -e 'display notification "💰💸" with title "GO" sound name "Hero"'
sleep 1500
osascript -e 'display notification "🎉🎈🎋🎊" with title "STOP" sound name "Ping"'
sleep 300