I hereby claim:
- I am onethirtyfive on github.
- I am onethirtyfive (https://keybase.io/onethirtyfive) on keybase.
- I have a public key whose fingerprint is AB42 5AB2 8DD7 9A67 27AA 2CFE FF30 B1CA 93CB 1225
To claim this, I am signing this object:
| blueprint: | |
| name: Sensor Light | |
| description: > | |
| # 💡 Sensor Light | |
| **Version: 6.5** | |
| Your lighting experience, your way - take control and customize it to perfection! 💡✨ |
I hereby claim:
To claim this, I am signing this object:
| class Base | |
| A_VALUE = 2 | |
| def foo | |
| end | |
| end | |
| module Refiner | |
| refine Base do | |
| def foo | |
| old_value = super |
I hereby claim:
To claim this, I am signing this object:
| /* | |
| * Javascript provider idiom illustrated | |
| * @author Susan Potter | |
| * @date 2011-01-28 | |
| */ | |
| // FinEnv "interface" | |
| var FinEnv = function () { | |
| return { | |
| println: function (output) { |
| letters = ['a', 'b', 'c', 'd'] | |
| letters.each do |letter| | |
| puts letter | |
| end | |
| => prints each letter. easy. | |
| # below, '' is an empty string. | |
| # result_string is initially '', the argument passed to inject. |
| # lib/api/presenters/detailed_post.rb | |
| module API | |
| module Presenters | |
| class DetailedPost | |
| include ActiveModel::Serializers::JSON | |
| include ActiveModel::Serializers::Xml | |
| attr_accessor :post | |
| delegate :attributes, :to => :post |
| source 'http://rubygems.org' | |
| RAILS_VERSION = '~> 3.1.0.rc4' | |
| DM_VERSION = '~> 1.1.0' | |
| RSPEC_VERSION = '~> 2.6.0' | |
| CUCUMBER_VERSION = '~> 1.0.0' | |
| gem 'activesupport', RAILS_VERSION, :require => 'active_support' | |
| gem 'actionpack', RAILS_VERSION, :require => 'action_pack' | |
| gem 'actionmailer', RAILS_VERSION, :require => 'action_mailer' |
| # This example is an alternative to implementing polymorphic associations | |
| # using an ActiveRecord-esque 'type' column. In this model, there are many | |
| # 'units.' Unit is an abstract supertype. Descendants are modeled referencing | |
| # a unit by 'unit_id', a foreign key to the primary key in the units model. | |
| # Note: This approach maintains referential integrity in the database via | |
| # descendants' FK to unit.id; however, it is the application's responsibility | |
| # to ensure that no two descendants reference the same unit. This is an | |
| # intrinsic limitation of the "Class Table Inheritance" approach, but it's | |
| # a lot better than maintaining "type" data that is opaque to the data store. |
| Here's the relevant part of the schema, simplified, showing relations: | |
| CREATE TABLE "units" ( | |
| "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT, | |
| "name" VARCHAR(50) | |
| ); | |
| CREATE TABLE "champions" ( | |
| "unit_id" INTEGER NOT NULL, | |
| "title" VARCHAR(50), |