Skip to content

Instantly share code, notes, and snippets.

View inkredabull's full-sized avatar

Anthony Bull inkredabull

View GitHub Profile

Was seeing this:

$ rbenv install 2.2.1
Downloading ruby-2.2.1.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/5a4de38068eca8919cb087d338c0c2e3d72c9382c804fb27ab746e6c7819ab28
Installing ruby-2.2.1...

BUILD FAILED (OS X 10.10.2 using ruby-build 20150413)
@inkredabull
inkredabull / javascript_client_side_package_management.md
Last active August 29, 2015 13:55
JS Client-side Package Management

At work, we're considering moving away from Require.js towards Browserify. I've spent some time reading up on; following are thoughts and resources.

tl;dr Browserify is worth introducing into our stack even though a Best Practice in the space hasn't emerged; Traceur is worth considering to hedge bets until ES6 is ready

Pro

  • took 30 mins to implement a feature on Friday using Browserify whose solution with our custom Require.js-based framework had eluded me for hours
  • building a center of excellence around an emerging (possible) standard
  • experience can be turned into blog posts
  • leverages the node package management module system -IMO dominant in the space (although I don't see us publishing our libs anytime soon)
@inkredabull
inkredabull / ab_testing_requirements.md
Last active January 4, 2016 03:39
A/B Testing Solution Requirements

For Rails

(No warranty provided on information accuracy; corrections appreciated.)

Vanity A/Bingo Bandit Split
Provides mechanism to see which experiment is assigned to which user for analytics purposes out-of-the-box x
Easy to install x x x x
Well-written dev docs x x x
Allows for weighted assignment (percentages) of experiment variations * x x
@inkredabull
inkredabull / performance_review_helper
Created December 4, 2013 17:31
One-line for parsing calendar-year Git history (minus 'merges') to assist in year-end performance review. (Replace author with your name, dates as appropriate.) awk ref: http://stackoverflow.com/questions/2626274/print-all-but-the-first-three-columns
git log --author=Anthony --since="JAN 1 2013" --until "Dec 31 2013" --oneline | awk -F ' ' '{for(i=2;i<=NF;i++)printf "%s",$i (i==NF?ORS:OFS)}' | grep -v Merge
@inkredabull
inkredabull / gist:6047314
Created July 21, 2013 03:05
"Cannot call method 'setup' of undefined" : ember-mocha-adapter
I ran into this issue while running Karma. Turns out I wasn't including the right lib and adapter in my karma.conf.js.
Had:
files = [
JASMINE,
JASMINE_ADAPTER
...
]
@inkredabull
inkredabull / 10.8.2.macvim.workaround.txt
Created January 9, 2013 13:19
Mac OSX 10.8.2 & MacVim Workaround
While running this:
brew install macvim
Was getting this:
Error: Can't run /Applications/Xcode.app/usr/bin/xcodebuild (no such file).
Then I found [1], so I did this:
@inkredabull
inkredabull / capybara_poltergeist_flush_example.rb
Created October 5, 2012 21:03
Use execute_script in conjunction with evaluate_script to flush JS global to STDOUT
# Essentially from the poltergeist code (see 'spec/integration/driver_spec.rb')
page.execute_script("window.result = 3;")
puts page.evaluate_script("result") # '3'
@inkredabull
inkredabull / gist:3693833
Created September 10, 2012 21:03
Using random number value generation in vim substitution
BACKGROUND
Given a JSON data file for one Use Case, I wanted to repurpose it
for two other, similar Use Cases while prototyping. Actual values
in the copied files didn't matter; they just needed to be different
to make the prototype appear different between Use Cases.
RESEARCH
I knew I wanted to do something like [1] so I did a Google search
@inkredabull
inkredabull / gist:3555497
Created August 31, 2012 16:33
Using dynamic val in vim substitution
BACKGROUND
Was using a file with a bunch of named data points [1]. Didn't
want to edit the name of each data point to repurpose it for my
prototyping efforts but needed a command mode substitution to
iterate over a visual block and do the replacement but with a
dynamic expression (line number is adequate.)
Found [2] and then figured out I'd need something like printf()
for use in eval() so stumbled upon [3].
@inkredabull
inkredabull / FirefoxSeleniumMacOSCPartII.txt
Created June 1, 2012 12:04
Fixing "Will you help improve Mozilla Firefox" message that appears while using Selenium under Mac OSX, Part II
In the end, I simply followed the instructions in [1].
That meant creating a new profile and accepting the security exception. Then
I updated SeleniumServer in the Selenium gem to make use of the profile (via
firefoxProfileTemplate) to get around the issue. See [2] for the latest.
[1] - http://saucelabs.com/blog/index.php/2010/01/selenium-totw-https-and-self-signed-certificate-exeptions/
[2] - https://github.com/inkredabull/selenium/