- Dynamic Dispatch
- Dynamic Method
- Ghost Methods
- Dynamic Proxies
- Blank Slate
- Kernel Method
- Flattening the Scope (aka Nested Lexical Scopes)
- Context Probe
- Class Eval (not really a 'spell' more just a demonstration of its usage)
- Class Macros
| # Trying to do app.get and getting dumb complaints from rails about the secret. Fuck off. | |
| module Rails | |
| class Application < Engine | |
| def validate_secret_key_config! | |
| true | |
| end | |
| end | |
| end | |
| module ActiveSupport |
| # frozen_string_literal: true | |
| source "https://rubygems.org" | |
| gem "rails" | |
| gem "rspec" | |
| gem "sqlite3" |
| require 'open-uri' | |
| File.open('vendors.md', 'a') do |f| | |
| host = URI.parse(ARGV.first).host | |
| if host.scan(/\./).length >= 2 | |
| host.gsub!(/www\./, '') if host =~ /^www/i | |
| end | |
| f << "1. [#{host}](#{host})\n" | |
| end |
| ### Keybase proof | |
| I hereby claim: | |
| * I am apanzerj on github. | |
| * I am apanzerj (https://keybase.io/apanzerj) on keybase. | |
| * I have a public key ASBTaR7_fYfnIQPakco3k6sBzmApguTeu0YF4vvKSIa5nwo | |
| To claim this, I am signing this object: |
I hereby claim:
- I am apanzerj on github.
- I am apanzerj (https://keybase.io/apanzerj) on keybase.
- I have a public key ASCQV268h7rdyIZB3FXjpd4NPYre3BA24qtDqjFVBG-eHAo
To claim this, I am signing this object:
| // Sometimes it's necessary to do a bit of clean-up | |
| Array.prototype.forEach.call(document.querySelectorAll('.js-comment-delete button'), function(el, i) { | |
| el.removeAttribute('data-confirm'); | |
| el.click(); | |
| }); |
| require "active_record" | |
| module Polite | |
| BAD_WORDS = ["fuck", "asshole", "motherfucker", "cunt", "cock", "dickhead"] | |
| ESCAPED = BAD_WORDS.collect {|word| Regexp.escape(word)} | |
| RE = /(#{ESCAPED.join("|")})/i | |
| def self.extended(base) | |
| base.extend ClassMethods | |
| end |
I was at Amazon for about six and a half years, and now I've been at Google for that long. One thing that struck me immediately about the two companies -- an impression that has been reinforced almost daily -- is that Amazon does everything wrong, and Google does everything right. Sure, it's a sweeping generalization, but a surprisingly accurate one. It's pretty crazy. There are probably a hundred or even two hundred different ways you can compare the two companies, and Google is superior in all but three of them, if I recall correctly. I actually did a spreadsheet at one point but Legal wouldn't let me show it to anyone, even though recruiting loved it.
I mean, just to give you a very brief taste: Amazon's recruiting process is fundamentally flawed by having teams hire for themselves, so their hiring bar is incredibly inconsistent across teams, despite various efforts they've made to level it out. And their operations are a mess; they don't real