Skip to content

Instantly share code, notes, and snippets.

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

Robert Pankowecki paneq

🏠
Working from home
View GitHub Profile
  • composition instead of inheritance
  • autodelegating unknkown methods to composed objects if choice is obvious
@paneq
paneq / gist:3103603
Created July 13, 2012 08:19 — forked from paulirish/gist:3098860
Open Conference Expectations

Open Conference Expectations

For conferences, it's extremely important that attendees get top-quality content from industry experts. As a highly compelling format of educating others based on experience and research, conferences stand to be one the best sources of refined knowledge available. Still, it's important for a successful event to have a few guidelines to ensure quality content from the best and most appropriate speakers. Below is a set of guidelines for conference organizers that ensure quality content for attendees and the community.

What We, As Speakers, Expect from Conferences

  1. Video recordings: Organizers should prioritize recording all talks and sessions. A conference that only teaches the ~300 people in the room has constrained value and is not worthwhile to a speaker who wants to benefit the community. When recorded, video will be available online under a permissive license (CC-BY-*) within six months of the event.

  2. Travel reimbursement: Conferences will reimburse travel

@paneq
paneq / test.rb
Created July 10, 2012 08:46
AgileGuiTesting terrible API
require 'java'
require 'AgileGuiTesting'
require 'AGTImageRecognition'
require 'minitest/unit'
require 'minitest/autorun'
ROBOCOP = @robot
class TestClicks < MiniTest::Unit::TestCase
def setup
@paneq
paneq / alias.rb
Created July 1, 2012 18:22
alias vs alias_method when used for class methods in ruby
# http://blog.bigbinary.com/2012/01/08/alias-vs-alias-method.html
class X
class << self
def skip
alias :scenario :skip_scenario
end
def scenario
puts "scenario"
@paneq
paneq / installation.log
Created June 15, 2012 08:51
`bundle install` won't install ffi as libnotify dependency but gem install will
(vm:sandbox) [rupert] 08:42 <1.9.3p194> ~/develop/rails_with_notification > gem uninstall ffi
You have requested to uninstall the gem:
ffi-1.0.11
libnotify-0.7.3 depends on [ffi (~> 1.0.0)]
If you remove this gems, one or more dependencies will not be met.
Continue with Uninstall? [Yn] y
Successfully uninstalled ffi-1.0.11
(vm:sandbox) [rupert] 08:42 <1.9.3p194> ~/develop/rails_with_notification > gem uninstall libnotify
Successfully uninstalled libnotify-0.7.3
@paneq
paneq / development.rb
Created June 14, 2012 22:46
Native operating system notifications about rails requests time
# config/environments/development.rb
NOTIFIER = case RUBY_PLATFORM
when /linux/
Bundler.require(:linux)
Proc.new{|title, text| Libnotify.show(:body => text, :summary => title) }
when /darwin|mac/
Bundler.require(:darwin)
Proc.new{|title, text| Growl.notify(text, :title => title) }
else
nil
@paneq
paneq / os.rb
Created June 14, 2012 22:45
Two ways of detecting operating system in Ruby
RbConfig::CONFIG['host_os']
RUBY_PLATFORM
@paneq
paneq / deploy.rb
Created June 14, 2012 22:44
Configure capistrano to skip gems required only on dev machines
set :bundle_without, [:development, :test, :linux, :darwin]
@paneq
paneq / config
Created June 14, 2012 22:43
.bundle/config after running `bundle install --without darwin`
---
BUNDLE_WITHOUT: darwin
@paneq
paneq / Gemfile
Created June 14, 2012 22:40
Proper way of specifying gems for different ruby platforms
group :linux do
gem 'ffi' # https://github.com/splattael/libnotify/issues/18
gem 'libnotify'
end
gem 'growl', :group => :darwin