Skip to content

Instantly share code, notes, and snippets.

View jamesgary's full-sized avatar

James Gary jamesgary

View GitHub Profile
#!/usr/bin/env ruby
require 'rubygems'
require 'gmail'
class SecretSanta
class << self
def get_secret_santas(people, couples)
invalid = true
while(invalid) do
@jamesgary
jamesgary / gist:5485061
Last active December 16, 2015 19:29
Testing HTTP APIs in Ruby - @shaiguitar - RailsConf 2013

Testing HTTP APIs in Ruby

@shaiguitar

  • Everything as a service
  • Test it!
  • Problem statement: Testing a server/client HTTP API
  • Good plan:
    • Create API
    • Build client lib that can be used in confusmer apps
  • Make it easy for consumer apps to test w/ our client library
@jamesgary
jamesgary / gist:5485331
Created April 29, 2013 22:31
Object-Oriented Lessons for a Service-Oriented World - Chris Kelly (@amateurhuman) - RailsConf 2013

Object-Oriented Lessons for a Service-Oriented World

Chris Kelly (@amateurhuman)

  • Works for New Relic as Happiness Engineer
  • These aren't hard principles, mostly ideas for now
  • Monorail - Monolithic Rails App
  • Network-based application software instead of SOA
  • (not necessarily building 'service')
  • Monorail (which is a mess) <-> Cache <-> Database
  • Your app is a special snowflake that breaks every time something changes.
  • Apt metaphor: Crystaline architecture shatters when a small thing changes
@jamesgary
jamesgary / gist:5485643
Created April 29, 2013 23:35
Incremental Design - Rebecca Miller-Webster and Savannah Wolf - RailsConf 2013

Incremental Design

Rebecca Miller-Webster and Savannah Wolf

  • Rebecca: Developer, Savannah: Designer

  • How do you make design changes?

  • Big redesigns are often long and frustrating

  • Designers throw the design over the wall

  • Developers either are confused by it, or 'screw it up'

  • Redesigning page by page can lead to technical debt, and is awkward

@jamesgary
jamesgary / gist:5485898
Created April 30, 2013 00:41
Humanity on Rails - Daniel Azuma - RailsConf 2013

Humanity on Rails

Daniel Azuma

  • What is 'living'?
  • RailsBridge: Org to increase diversity in tech
  • Diversity's a big issue
  • How do we attract more minorities?
  • Yahoo recently canned their remote working program
  • What do we make of all of this?
  • Daniel got laid off, went back to school to study theology at Regent
@jamesgary
jamesgary / gist:5486112
Created April 30, 2013 01:34
Michael Lopp Keynote @rands - Stable & Volatiles - RailsConf 2013

Michael Lopp Keynote @rands

Stables and Volatiles

  • Humans are bad at making decisions (see eletrical outlets)

  • Why no one single plug?

  • Look at Apple's plugs

  • You're in a hurry

  • Your gig has an expiration date

  • Switch jobs about every 3 years

@jamesgary
jamesgary / gist:5491098
Created April 30, 2013 19:05
Rails vs. The Client - Noel Rappin (@noelrap) - RailsConf 2013

Rails vs. The Client

Noel Rappin (@noelrap)

  • Problem: Want users to have "rich client exp" (even though clients don't know what that means)
  • @dhh and @wycats offer different opinions (document vs json api)
  • But @noelrap just wants to write an e-commerce site
  • We tend to split stuff up into client stuff and server stuff between the user and data
  • @dhh says that the focus is on the server. The app lives on the server
  • @wycats says that the client is the focus, and the server just does whatever the client can't do (i.e. validation, persistence)
  • Where does the heart of your application live?
@jamesgary
jamesgary / gist:5491390
Last active July 26, 2022 09:06
The Magic Tricks of Testing - Sandi Metz - RailsConf2013

The Magic Tricks of Testing

Sandi Metz

  • Many people say "I hate my tests"
  • They kill your productivity when they're slow
  • A little change can break your tests (even if they shouldn't)
  • They're expensive
  • They are misery incarnate
  • Just delete some tests
  • You may have too many tests testing the wrong tests
@jamesgary
jamesgary / gist:5492121
Created April 30, 2013 21:33
From Rails to the web server to client to browser - David Padilla (@dabit) - RailsConf 2013

From Rails to the web server to client to browser

David Padilla @dabit

  • Life of a request
    • Browser creates request
    • Sends it to webserver (Unicorn)
    • Sends it to Rails
    • Sends it to spaghetti code
    • HTML is returned
  • Rack's job is to communicate between webservers and frameworks
@jamesgary
jamesgary / gist:5492397
Last active December 16, 2015 20:29
What Ruby developers can learn from Go - Lionel Barrow @lionelbarrow - RailsConf 2013

What Ruby developers can learn from Go

Lionel Barrow @lionelbarrow

  • Go is compiled, garbage collected, strongly typed, OO
  • Lower level than Ruby, but still aimed at web
  • Go has an agenda
    • Not welcome to a lot of styles of writing code
    • Prodded to write code in a certain way
    • Ruby doesn't have an agenda, but it does have idioms
  • What are the design goals here?