Skip to content

Instantly share code, notes, and snippets.

View stephankaag's full-sized avatar
🏠
Working from home

Stephan Kaag stephankaag

🏠
Working from home
View GitHub Profile
# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
# editor.onDidSave ->
@stephankaag
stephankaag / gist:77dd188b163c2ae4c719
Created November 17, 2015 12:17
MySQL 5.7 failures
MacBook-Pro-van-Stephan-2:do_mysql stephankaag$ rspec spec/command_spec.rb
DataObjects::Mysql::Command
it should behave like a Command
should be a kind of DataObjects::Command
should respond to #execute_non_query
should respond to #execute_reader
should respond to #set_types
should respond to #to_s
execute_non_query

Keybase proof

I hereby claim:

  • I am stephankaag on github.
  • I am stephankaag (https://keybase.io/stephankaag) on keybase.
  • I have a public key whose fingerprint is A9CF CE21 46BE 136F EB81 68F9 A411 2FEA EA30 4A8D

To claim this, I am signing this object:

@stephankaag
stephankaag / gist:6462995
Created September 6, 2013 12:14
With context
loadPath: function() {
_.each(this.path.models(), function(model, index) {
this.loadModel(model, index);
}, this);
}
#!/usr/bin/env bash
# Update Chromium (on OS X) to the latest nightly build.
install_dir='/Applications/Chromium.app'
base_url='http://commondatastorage.googleapis.com/chromium-browser-snapshots/Mac'
build=$(curl -s -f ${base_url}/LAST_CHANGE)
installed=$(/usr/libexec/PlistBuddy -c 'Print :SCMRevision' ${install_dir}/Contents/Info.plist)
script=$(basename $0)
@stephankaag
stephankaag / gist:1901565
Created February 24, 2012 15:16
DataMapper collection bug
require 'rubygems'
dm_version = "=1.2.0"
gem "dm-core", dm_version
require 'dm-core'
gem "dm-migrations", dm_version
require 'dm-migrations'
class Thing
class Order < ActiveRecord::Base
has_many :order_items, :inverse_of => :order
accepts_nested_attributes_for :order_items
end
class OrderItem < ActiveRecord::Base
belongs_to :order, :inverse_of => :order_items
accepts_nested_attributes_for :order
end