SlideShare a Scribd company logo
1 of 64
Download to read offline
Ruby Can Haz
                         EVERYONE!
                          Mikel Lindsaar
                           @raasdnil




Friday, 22 April 2011
Working in Rails & Ruby for 5+ Years

    Author of Mail, maintain TMail

    Rails Committer

    Entrepreneur

    http://stillalive.com/

    http://rubyx.com/




Friday, 22 April 2011
Example of StillAlive.com
                          Full stack production
                        monitoring for your app




Friday, 22 April 2011
Ruby Wants You




Friday, 22 April 2011
MINSWAN
                        Matz is nice, so we are nice




Friday, 22 April 2011
Scratch Your Own Itch




Friday, 22 April 2011
How do I start?

                            Patch a library


                           Write a library




Friday, 22 April 2011
Patch a Library




Friday, 22 April 2011
6 Steps to Patch
                              Fork on GitHub
                                    Clone
                           Write a failing test case
                        Run the tests { Fix the code }
                              Push to your fork
                             Send a pull request

Friday, 22 April 2011
Fork




Friday, 22 April 2011
Fork




Friday, 22 April 2011
Clone




Friday, 22 April 2011
Clone




Friday, 22 April 2011
Write a Failing Test Case




Friday, 22 April 2011
Write a Failing Test Case




Friday, 22 April 2011
Fix the Code




Friday, 22 April 2011
Fix the Code




Friday, 22 April 2011
Run the tests

                                Multiple Rubies?


                        Make it greener than you started




Friday, 22 April 2011
Push to your fork

                            Detailed commit message


                        Don’t push changes to the version




Friday, 22 April 2011
Send a Pull Request




Friday, 22 April 2011
Send a Pull Request




Friday, 22 April 2011
Profit




Friday, 22 April 2011
Write a Library




Friday, 22 April 2011
README Driven Dev




Friday, 22 April 2011
README Driven Dev




Friday, 22 April 2011
README Driven Dev

                                 tom.preston-werner.com

                         Google “README Driven Development”

                        2010/08/23/readme-driven-development.html




Friday, 22 April 2011
Write your Wish List




Friday, 22 April 2011
Write your Wish List




Friday, 22 April 2011
Friday, 22 April 2011
Friday, 22 April 2011
Research as Needed




Friday, 22 April 2011
Research as Needed


                                         RFCs




Friday, 22 April 2011
Research as Needed


                                         RFCs




Friday, 22 April 2011
Setup Your Gem

                        Read http://docs.rubygems.org/read/book/7

                           Create a simple directory structure

                                  Get your tests failing




Friday, 22 April 2011
Simple Gem Creation
                              You don’t need no tools

                          http://github.com/rubyx/nugget

                          Builds a gem skeleton with ruby

           $ ruby -s <(curl -s https://github.com/rubyx/nugget/raw/master/install.rb)




Friday, 22 April 2011
More on Nugget
                             http://github.com/rubyx/nugget

                        Need to do lots of things to get started

                        Lowers barrier to entry to release a gem

                5 minutes => Nothing to published on rubygems


Friday, 22 April 2011
Nugget File Structure




Friday, 22 April 2011
Nugget Patches Wanted
                        http://github.com/rubyx/nugget

                            Add test unit support

                             Rails gem support?

                                Make it a gem


Friday, 22 April 2011
Test First Development
                        I use RSpec because I am lazy and forget stuff

                               EVERYTHING in Mail is BDD

                                     Regressions Caught

                                      Seriously - do it



Friday, 22 April 2011
Testing for Libraries
                                   Start Simple

                          Comments in Spec Files are OK

                              Use Custom Matchers

                           Break Down Your Spec Files

                              Spec in Multiple Rubies


Friday, 22 April 2011
Start Somewhere




Friday, 22 April 2011
Start Somewhere




Friday, 22 April 2011
Start Simple




Friday, 22 April 2011
Start Simple




Friday, 22 April 2011
Comments are OK




Friday, 22 April 2011
Comments are OK




Friday, 22 April 2011
Use Custom Matchers
                               when appropriate




Friday, 22 April 2011
Use Custom Matchers
                               when appropriate




Friday, 22 April 2011
Use Custom Matchers
                               when appropriate




Friday, 22 April 2011
Use Custom Matchers
                               when appropriate




Friday, 22 April 2011
Break Down Spec Files




Friday, 22 April 2011
Break Down Spec Files
                                  26 Sub Directories

                                  79 Ruby Spec Files

                                  73 Edge Case Emails

                                  Many Many Lines of Specs

                                  1,289 examples

                                  No Failures :)
Friday, 22 April 2011
Spec in Multiple Rubies
                        Have to be a good Ruby Citizen

                               MRI - 1.8.7, 1.9.2

                                    JRuby

                                     REE

                                   Rubinius

Friday, 22 April 2011
Devil is in the Detail




Friday, 22 April 2011
Devil is in the Detail
                               And Thats It!

                               Simple Hey?




Friday, 22 April 2011
Devil is in the Detail
           Header Errors                     Legacy Emails
      Parsers     rfc822      Delivery Agents
                       And Thats It!           SMTP
   Body Decoding
          SPAM       PGP Signing       POP3 File Types
    Mbox               Simple Hey?              Network
               IMAP           Language Support
Sendmail Delivery Bad Emails              Encoding
                             Edge Cases
  Pattern Matching
                    OMGMIME! Decoding Attachments
     Interceptors
                         File IO    Domain Key Emails
       Observers                  Status Reports
          Inline Attachments
Friday, 22 April 2011
Listen to your Users




Friday, 22 April 2011
Listen to your Users
                              (but not blindly)




Friday, 22 April 2011
Listen to your Users
                              (but not blindly)




Friday, 22 April 2011
Have Good Specs




Friday, 22 April 2011
Encourage Participation
                                     MIT License

                           Clear “How to Test” Instructions

                        Clear “How to Contribute” Instructions

                                   Modular Design

                               Mail has 53 contributors


Friday, 22 April 2011
Release Often




Friday, 22 April 2011
Questions?
                                                   Mikel Lindsaar
                                                       @raasdnil

                                   RubyX.com                             StillAlive.com

                                                   We are hiring!


                        I can fix thiz: http://netherregionoftheearthii.blogspot.com/2010_04_18_archive.html
                                           Video Cat: http://www.coolfunnycats.com/?p=1954
                                   Repair Cat: http://www.mike2.com/category/animals/cats/page/4/
                                              All Other Cats: http://icanhascheezburger.com/

Friday, 22 April 2011
Friday, 22 April 2011

More Related Content

Similar to Ruby can haz Everyone

Form project why is the sky blue and other questions
Form project  why is the sky blue and other questionsForm project  why is the sky blue and other questions
Form project why is the sky blue and other questions
aakashm
 
The Productive Researcher's Technology Toolbox
The Productive Researcher's Technology ToolboxThe Productive Researcher's Technology Toolbox
The Productive Researcher's Technology Toolbox
Stratepedia Presentations
 
PyconUA - How to build ERP application having fun?
PyconUA - How to build ERP application having fun?PyconUA - How to build ERP application having fun?
PyconUA - How to build ERP application having fun?
Andrew Mleczko
 
Conquistando el Servidor con Node.JS
Conquistando el Servidor con Node.JSConquistando el Servidor con Node.JS
Conquistando el Servidor con Node.JS
Caridy Patino
 
Clouds against the Floods (RubyConfBR2011)
Clouds against the Floods (RubyConfBR2011) Clouds against the Floods (RubyConfBR2011)
Clouds against the Floods (RubyConfBR2011)
Leonardo Borges
 

Similar to Ruby can haz Everyone (20)

clrh58
clrh58clrh58
clrh58
 
Mozilla: Continuous Deploment on SUMO
Mozilla: Continuous Deploment on SUMOMozilla: Continuous Deploment on SUMO
Mozilla: Continuous Deploment on SUMO
 
ExpOn 2011 - Diego Monteiro - Níveis de Maturidade nas Mídias Sociais
ExpOn 2011 - Diego Monteiro - Níveis de Maturidade nas Mídias SociaisExpOn 2011 - Diego Monteiro - Níveis de Maturidade nas Mídias Sociais
ExpOn 2011 - Diego Monteiro - Níveis de Maturidade nas Mídias Sociais
 
Gradle - The hackable build-tool
Gradle - The hackable build-toolGradle - The hackable build-tool
Gradle - The hackable build-tool
 
Form project why is the sky blue and other questions
Form project  why is the sky blue and other questionsForm project  why is the sky blue and other questions
Form project why is the sky blue and other questions
 
Jono mozilla-talk
Jono mozilla-talkJono mozilla-talk
Jono mozilla-talk
 
the role of the future academic library...
the role of the future academic library...the role of the future academic library...
the role of the future academic library...
 
Namesmatter
NamesmatterNamesmatter
Namesmatter
 
20110721 pankaku us
20110721 pankaku us20110721 pankaku us
20110721 pankaku us
 
clrh56
clrh56clrh56
clrh56
 
Doctrine in the Real World
Doctrine in the Real WorldDoctrine in the Real World
Doctrine in the Real World
 
The Productive Researcher's Technology Toolbox
The Productive Researcher's Technology ToolboxThe Productive Researcher's Technology Toolbox
The Productive Researcher's Technology Toolbox
 
Giving goodpresentations
Giving goodpresentationsGiving goodpresentations
Giving goodpresentations
 
Selenium Page Objects101
Selenium Page Objects101Selenium Page Objects101
Selenium Page Objects101
 
PyconUA - How to build ERP application having fun?
PyconUA - How to build ERP application having fun?PyconUA - How to build ERP application having fun?
PyconUA - How to build ERP application having fun?
 
Distribute the workload, PHPTek, Amsterdam, 2011
Distribute the workload, PHPTek, Amsterdam, 2011Distribute the workload, PHPTek, Amsterdam, 2011
Distribute the workload, PHPTek, Amsterdam, 2011
 
Can Metadata Keep Libraries Relevant?
Can Metadata Keep Libraries Relevant?Can Metadata Keep Libraries Relevant?
Can Metadata Keep Libraries Relevant?
 
Caridy patino - node-js
Caridy patino - node-jsCaridy patino - node-js
Caridy patino - node-js
 
Conquistando el Servidor con Node.JS
Conquistando el Servidor con Node.JSConquistando el Servidor con Node.JS
Conquistando el Servidor con Node.JS
 
Clouds against the Floods (RubyConfBR2011)
Clouds against the Floods (RubyConfBR2011) Clouds against the Floods (RubyConfBR2011)
Clouds against the Floods (RubyConfBR2011)
 

Recently uploaded

Recently uploaded (20)

Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 

Ruby can haz Everyone