SlideShare a Scribd company logo
1 of 30
Optimizing for Programmer
Happiness
Or my seven year love affair with Ruby
Once upon a time...
Not Mine :-(
Josh Schramm
TW: @joshreedschramm
Level Seven
Today’s Talk
Why do people show up every month to talk about Ruby?
Discussion not a lecture
Mix of new people and “vets”.
Lots of opinion in these slides. References where referenceable
History, Culture (both ‘social’ and programming), unique parts of the language and
impact on the industry. Not much code
History Lesson - Founding Fathers
Yukihiro Matsumoto “Matz”
Invented the Ruby Language in ‘93, first release in
‘95
Influenced by Perl, Eiffel, Ada, Lisp and Smalltalk
Much of the culture of the Ruby community comes
from the principals Matz followed when building out
the early versions of the language
History Lesson - Founding Fathers
David Heinemeier Hansson “DHH”
Invented the Ruby on Rails web framework. First
release in 2005
Founder of 37signals (now Basecamp)
Coauthor of Agile Web Development w/ Rails
(along with Dave Thomas and Sam Ruby)
Rails was largely responsible for the rise in
popularity of the Ruby language.
Inflection point in 2006
Jim Weirich
Inventor of Rake, co-founder/early contributor to Rubygems
Was a prominent conference speaker
_why the lucky stiff
Wrote the semi-irreverent “Why’s (poignant) Guide to
Ruby”
Yehuda Katz
Co-inventor of Merb, an early Rails competitor that
merged w/ Rails. It helped introduce modularity to Rails.
The Ruby Way
“Matz is nice and so we are nice”
- Early culture of niceness, inclusiveness and evangelism.
- Lead to a spike in user groups, conferences and events (like Rails Rumble)
- Regional conferences took off (Windy City Rails, Madison Ruby, Steel City
Ruby, Great Lakes Ruby Bash)
- Evangelism gave way to great tools for learning the language:
- Ex: Ruby Koans, Try Ruby
Is this still true?
Culture of the Code
Principle of Least Astonishment (POLA)
- The language should minimize confusion amongst experienced users.
- Matz’s early driving design principle
- Confusing to whom?
Optimized for Programmer Happiness
- Inspired by POLA
- Language decisions are intended to delight the user (the programmer) even if
that has performance, verboseness or other tradeoffs.
The Rails Doctrine
Convention over Configuration
- Starts from the position of opinionated software. That most use cases in web
development are similar and we shouldn’t reinvent the wheel every time.
Push Up a Big Tent
- That said, the tool should support customization and the introduction of new
tools if people prefer / have valid use cases.
- Ex: RSpec over MiniTest / TestUnit
More: http://rubyonrails.org/doctrine/
_Why Ruby? - Dynamic
With Ruby you can manipulate or modify the program you are running as it runs.
Part of a concept known as metaprogramming.
_Why Ruby? - Dynamically and Strongly Typed
Dynamic Typing: A variable can change type to whatever you assign to it.
Strong Typing: You cannot perform an action on a variable that doesn’t make
sense for the current type.
_Why Ruby? - Reflective
You can inspect the characteristics of a class, method, variable at runtime.
Combine this with the dynamic language features and dynamic typing and you can
make decisions about what your code should be based on what your code
currently is.
How very zen
There are no primitive types in Ruby. Literally everything you interact with is an
object of some sort. A class, an instance of a class, etc.
Contrast with .NET / Java / C where int, char, decimal and several others are
primitives, not objects
Main differences
Primitives tend to be faster to interact with, pull out of memory and copy but
immutable and inflexible.
Objects are slower, more memory but far more flexible
_Why Ruby? - Everything is an Object (Super OO)
_Why Ruby? - Lack of Ceremony
Ruby syntax tends to be clean(er) and devoid of most markers that other
languages require like semicolons or parentheses
At the same time ruby can support those things if preferred
_Why Ruby? - Domain Specific Languages
Ruby tools are usually written to be expressive and easy to read. They leverage a
concept called DSL to describe the actions the tool can take.
Ex: Rspec
Why Not Ruby?
Ruby and Rails’ Impact - RubyGems
One of the most comprehensive dependency management / library distribution
tools anywhere at its release.
Helped contribute to rise of social coding
Inspired other platforms: NuGet (.NET), Composer (PHP), CocoaPods
(Swift/Obj-C), NPM (Node.JS)
Ruby and Rails’ Impact - Testing
Flexibility of the language drove the rise in BDD and ATDD as a first class
practice.
Tools like: RSpec, Cucumber, Capybara, Watir
Inspired other platforms: SpecFlow (.NET), Watin/Watij (.NET/Java), Jasmine
(Javascript)
Ruby and Rails’ Impact - Web MVC
Rails implementation of a full-stack web framework designed around a Model
View Controller architecture became the standard for framework design for about
a decade.
Just now starting to see a change to this with API driven, single page apps and
functional programming.
Inspired other platforms: ASP.Net MVC (.NET), Play (Java and Scala), Laravel /
CodeIgniter (PHP)
Ruby and Rails’ Impact - DevOps
The DSL features of Rails helped spur the adoption of configurable operations
tooling. It became easier to automate the setup of infrastructure and ultimately
spawned an entire “new” category of IT.
Examples: Chef / Puppet
Ruby and Rails’ Impact - Opinionated Programming
Rails “Convention over Configuration” mantra broke down some of the stigma
associated with setting intelligent defaults in frameworks / tools.
Now most platforms package with a preferred DBMS, View Layer, Emailing Tool,
etc. even if they are customizable.
Ex: ASP.Net MVC with Entity Framework
Questions / Discussion

More Related Content

Viewers also liked

Twitter for Nontraditional Businesses
Twitter for Nontraditional BusinessesTwitter for Nontraditional Businesses
Twitter for Nontraditional BusinessesRachel Ciprotti
 
Cloud storage services
Cloud storage servicesCloud storage services
Cloud storage servicesHiroki Kaneko
 
Role of Public Art in Environmental movements
Role of Public Art in Environmental movementsRole of Public Art in Environmental movements
Role of Public Art in Environmental movementsTanaya Lal
 
Customer orientation مشتری مداری
Customer orientation مشتری مداریCustomer orientation مشتری مداری
Customer orientation مشتری مداریSalim Khalili
 
внешняя память
внешняя памятьвнешняя память
внешняя памятьShmonium
 
Iso10002 مدیریت شکایت و رضایت مشتری
Iso10002 مدیریت شکایت و رضایت مشتریIso10002 مدیریت شکایت و رضایت مشتری
Iso10002 مدیریت شکایت و رضایت مشتریSalim Khalili
 
Down Syndrome
Down Syndrome Down Syndrome
Down Syndrome Epi1995
 
Connecting ti cc2541 with i os
Connecting ti cc2541 with i osConnecting ti cc2541 with i os
Connecting ti cc2541 with i osHiroki Kaneko
 
The Republic کتاب جمهور افلاطون
The Republic  کتاب جمهور  افلاطونThe Republic  کتاب جمهور  افلاطون
The Republic کتاب جمهور افلاطونSalim Khalili
 
Doing Business With Nestle
Doing Business With NestleDoing Business With Nestle
Doing Business With NestleDoug Rader
 
Archetypes شخصیت شناسی مفاهیم اولیه
Archetypes شخصیت شناسی مفاهیم اولیهArchetypes شخصیت شناسی مفاهیم اولیه
Archetypes شخصیت شناسی مفاهیم اولیهSalim Khalili
 
Business etiquette آداب معاشرت کسب و کار
Business etiquette آداب معاشرت کسب و کارBusiness etiquette آداب معاشرت کسب و کار
Business etiquette آداب معاشرت کسب و کارSalim Khalili
 
Body language زبان بدن
Body language  زبان بدن Body language  زبان بدن
Body language زبان بدن Salim Khalili
 
Le social commerce
Le social commerceLe social commerce
Le social commerceCYB@RDECHE
 

Viewers also liked (20)

Twitter for Nontraditional Businesses
Twitter for Nontraditional BusinessesTwitter for Nontraditional Businesses
Twitter for Nontraditional Businesses
 
Cloud storage services
Cloud storage servicesCloud storage services
Cloud storage services
 
Password management
Password managementPassword management
Password management
 
Using MVNO at Japan
Using MVNO at JapanUsing MVNO at Japan
Using MVNO at Japan
 
Blog
BlogBlog
Blog
 
Role of Public Art in Environmental movements
Role of Public Art in Environmental movementsRole of Public Art in Environmental movements
Role of Public Art in Environmental movements
 
Air bnb host_diary
Air bnb host_diaryAir bnb host_diary
Air bnb host_diary
 
Customer orientation مشتری مداری
Customer orientation مشتری مداریCustomer orientation مشتری مداری
Customer orientation مشتری مداری
 
внешняя память
внешняя памятьвнешняя память
внешняя память
 
Iso10002 مدیریت شکایت و رضایت مشتری
Iso10002 مدیریت شکایت و رضایت مشتریIso10002 مدیریت شکایت و رضایت مشتری
Iso10002 مدیریت شکایت و رضایت مشتری
 
Down Syndrome
Down Syndrome Down Syndrome
Down Syndrome
 
Connecting ti cc2541 with i os
Connecting ti cc2541 with i osConnecting ti cc2541 with i os
Connecting ti cc2541 with i os
 
The Republic کتاب جمهور افلاطون
The Republic  کتاب جمهور  افلاطونThe Republic  کتاب جمهور  افلاطون
The Republic کتاب جمهور افلاطون
 
Doing Business With Nestle
Doing Business With NestleDoing Business With Nestle
Doing Business With Nestle
 
Archetypes شخصیت شناسی مفاهیم اولیه
Archetypes شخصیت شناسی مفاهیم اولیهArchetypes شخصیت شناسی مفاهیم اولیه
Archetypes شخصیت شناسی مفاهیم اولیه
 
Presentation
PresentationPresentation
Presentation
 
Business etiquette آداب معاشرت کسب و کار
Business etiquette آداب معاشرت کسب و کارBusiness etiquette آداب معاشرت کسب و کار
Business etiquette آداب معاشرت کسب و کار
 
Body language زبان بدن
Body language  زبان بدن Body language  زبان بدن
Body language زبان بدن
 
Internet, la messagerie - Office de Tourisme Val de Cher Saint-Aignan
Internet, la messagerie - Office de Tourisme Val de Cher Saint-AignanInternet, la messagerie - Office de Tourisme Val de Cher Saint-Aignan
Internet, la messagerie - Office de Tourisme Val de Cher Saint-Aignan
 
Le social commerce
Le social commerceLe social commerce
Le social commerce
 

Similar to Optimizing for programmer happiness

Ruby on Rails Introduction M&P - IT Skill Development Program 07
Ruby on Rails Introduction M&P - IT Skill Development Program 07Ruby on Rails Introduction M&P - IT Skill Development Program 07
Ruby on Rails Introduction M&P - IT Skill Development Program 07Muhammad Sunny ✈
 
Ruby on Rails Fundamentals, Class 1
Ruby on Rails Fundamentals, Class 1Ruby on Rails Fundamentals, Class 1
Ruby on Rails Fundamentals, Class 1Sarah Allen
 
Languages used by web app development services remotestac x
Languages used by web app development services  remotestac xLanguages used by web app development services  remotestac x
Languages used by web app development services remotestac xRemote Stacx
 
Ruby On Rails Presentation
Ruby On Rails PresentationRuby On Rails Presentation
Ruby On Rails PresentationPaul Pajo
 
From Java to Ruby...and Back
From Java to Ruby...and BackFrom Java to Ruby...and Back
From Java to Ruby...and BackAnil Hemrajani
 
Ruby Rails Web Development.pdf
Ruby Rails Web Development.pdfRuby Rails Web Development.pdf
Ruby Rails Web Development.pdfAyesha Siddika
 
Ruby vs Java: Comparing Two Popular Programming Languages For Developing Ente...
Ruby vs Java: Comparing Two Popular Programming Languages For Developing Ente...Ruby vs Java: Comparing Two Popular Programming Languages For Developing Ente...
Ruby vs Java: Comparing Two Popular Programming Languages For Developing Ente...Katy Slemon
 
Life Beyond Rails: Creating Cross Platform Ruby Apps
Life Beyond Rails: Creating Cross Platform Ruby AppsLife Beyond Rails: Creating Cross Platform Ruby Apps
Life Beyond Rails: Creating Cross Platform Ruby AppsTristan Gomez
 
Ruby On Rails - Rochester K Linux User Group
Ruby On Rails - Rochester K Linux User GroupRuby On Rails - Rochester K Linux User Group
Ruby On Rails - Rochester K Linux User GroupJose de Leon
 
Ruby on Rails (RoR) as a back-end processor for Apex
Ruby on Rails (RoR) as a back-end processor for Apex Ruby on Rails (RoR) as a back-end processor for Apex
Ruby on Rails (RoR) as a back-end processor for Apex Espen Brækken
 
Exploring metaprogramming using Ruby language
Exploring metaprogramming using Ruby languageExploring metaprogramming using Ruby language
Exploring metaprogramming using Ruby languageHarshal Hayatnagarkar
 
Unit 4 Assignment 1 Comparative Study Of Programming...
Unit 4 Assignment 1 Comparative Study Of Programming...Unit 4 Assignment 1 Comparative Study Of Programming...
Unit 4 Assignment 1 Comparative Study Of Programming...Carmen Sanborn
 
Ruby on Rails Training - Module 1
Ruby on Rails Training - Module 1Ruby on Rails Training - Module 1
Ruby on Rails Training - Module 1Mark Menard
 
Ruby On Rails
Ruby On RailsRuby On Rails
Ruby On Railsiradarji
 
Ruby Past, Present, Future
Ruby   Past, Present, FutureRuby   Past, Present, Future
Ruby Past, Present, Futureadamfine
 
Dynamic Languages on the JVM
Dynamic Languages on the JVMDynamic Languages on the JVM
Dynamic Languages on the JVMelliando dias
 
A Strong Object Recognition Using Lbp, Ltp And Rlbp
A Strong Object Recognition Using Lbp, Ltp And RlbpA Strong Object Recognition Using Lbp, Ltp And Rlbp
A Strong Object Recognition Using Lbp, Ltp And RlbpRikki Wright
 
Ruby on Rails : First Mile
Ruby on Rails : First MileRuby on Rails : First Mile
Ruby on Rails : First MileGourab Mitra
 

Similar to Optimizing for programmer happiness (20)

Ruby on Rails Introduction M&P - IT Skill Development Program 07
Ruby on Rails Introduction M&P - IT Skill Development Program 07Ruby on Rails Introduction M&P - IT Skill Development Program 07
Ruby on Rails Introduction M&P - IT Skill Development Program 07
 
Ruby on Rails Fundamentals, Class 1
Ruby on Rails Fundamentals, Class 1Ruby on Rails Fundamentals, Class 1
Ruby on Rails Fundamentals, Class 1
 
Languages used by web app development services remotestac x
Languages used by web app development services  remotestac xLanguages used by web app development services  remotestac x
Languages used by web app development services remotestac x
 
Ruby On Rails Presentation
Ruby On Rails PresentationRuby On Rails Presentation
Ruby On Rails Presentation
 
From Java to Ruby...and Back
From Java to Ruby...and BackFrom Java to Ruby...and Back
From Java to Ruby...and Back
 
Ruby Rails Web Development.pdf
Ruby Rails Web Development.pdfRuby Rails Web Development.pdf
Ruby Rails Web Development.pdf
 
Ruby vs Java: Comparing Two Popular Programming Languages For Developing Ente...
Ruby vs Java: Comparing Two Popular Programming Languages For Developing Ente...Ruby vs Java: Comparing Two Popular Programming Languages For Developing Ente...
Ruby vs Java: Comparing Two Popular Programming Languages For Developing Ente...
 
Life Beyond Rails: Creating Cross Platform Ruby Apps
Life Beyond Rails: Creating Cross Platform Ruby AppsLife Beyond Rails: Creating Cross Platform Ruby Apps
Life Beyond Rails: Creating Cross Platform Ruby Apps
 
Ruby On Rails - Rochester K Linux User Group
Ruby On Rails - Rochester K Linux User GroupRuby On Rails - Rochester K Linux User Group
Ruby On Rails - Rochester K Linux User Group
 
Ruby on Rails (RoR) as a back-end processor for Apex
Ruby on Rails (RoR) as a back-end processor for Apex Ruby on Rails (RoR) as a back-end processor for Apex
Ruby on Rails (RoR) as a back-end processor for Apex
 
Exploring metaprogramming using Ruby language
Exploring metaprogramming using Ruby languageExploring metaprogramming using Ruby language
Exploring metaprogramming using Ruby language
 
Unit 4 Assignment 1 Comparative Study Of Programming...
Unit 4 Assignment 1 Comparative Study Of Programming...Unit 4 Assignment 1 Comparative Study Of Programming...
Unit 4 Assignment 1 Comparative Study Of Programming...
 
Ruby on Rails Training - Module 1
Ruby on Rails Training - Module 1Ruby on Rails Training - Module 1
Ruby on Rails Training - Module 1
 
Ruby On Rails
Ruby On RailsRuby On Rails
Ruby On Rails
 
Ruby Past, Present, Future
Ruby   Past, Present, FutureRuby   Past, Present, Future
Ruby Past, Present, Future
 
Dynamic Languages on the JVM
Dynamic Languages on the JVMDynamic Languages on the JVM
Dynamic Languages on the JVM
 
Why Ruby?
Why Ruby? Why Ruby?
Why Ruby?
 
A Strong Object Recognition Using Lbp, Ltp And Rlbp
A Strong Object Recognition Using Lbp, Ltp And RlbpA Strong Object Recognition Using Lbp, Ltp And Rlbp
A Strong Object Recognition Using Lbp, Ltp And Rlbp
 
Ruby on Rails : First Mile
Ruby on Rails : First MileRuby on Rails : First Mile
Ruby on Rails : First Mile
 
1 Intro
1   Intro1   Intro
1 Intro
 

Recently uploaded

Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentationphoebematthew05
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsHyundai Motor Group
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 

Recently uploaded (20)

Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentation
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 

Optimizing for programmer happiness

  • 1. Optimizing for Programmer Happiness Or my seven year love affair with Ruby
  • 2. Once upon a time... Not Mine :-(
  • 4. Today’s Talk Why do people show up every month to talk about Ruby? Discussion not a lecture Mix of new people and “vets”. Lots of opinion in these slides. References where referenceable History, Culture (both ‘social’ and programming), unique parts of the language and impact on the industry. Not much code
  • 5. History Lesson - Founding Fathers Yukihiro Matsumoto “Matz” Invented the Ruby Language in ‘93, first release in ‘95 Influenced by Perl, Eiffel, Ada, Lisp and Smalltalk Much of the culture of the Ruby community comes from the principals Matz followed when building out the early versions of the language
  • 6. History Lesson - Founding Fathers David Heinemeier Hansson “DHH” Invented the Ruby on Rails web framework. First release in 2005 Founder of 37signals (now Basecamp) Coauthor of Agile Web Development w/ Rails (along with Dave Thomas and Sam Ruby) Rails was largely responsible for the rise in popularity of the Ruby language. Inflection point in 2006
  • 7. Jim Weirich Inventor of Rake, co-founder/early contributor to Rubygems Was a prominent conference speaker _why the lucky stiff Wrote the semi-irreverent “Why’s (poignant) Guide to Ruby” Yehuda Katz Co-inventor of Merb, an early Rails competitor that merged w/ Rails. It helped introduce modularity to Rails.
  • 8. The Ruby Way “Matz is nice and so we are nice” - Early culture of niceness, inclusiveness and evangelism. - Lead to a spike in user groups, conferences and events (like Rails Rumble) - Regional conferences took off (Windy City Rails, Madison Ruby, Steel City Ruby, Great Lakes Ruby Bash) - Evangelism gave way to great tools for learning the language: - Ex: Ruby Koans, Try Ruby Is this still true?
  • 9. Culture of the Code Principle of Least Astonishment (POLA) - The language should minimize confusion amongst experienced users. - Matz’s early driving design principle - Confusing to whom? Optimized for Programmer Happiness - Inspired by POLA - Language decisions are intended to delight the user (the programmer) even if that has performance, verboseness or other tradeoffs.
  • 10. The Rails Doctrine Convention over Configuration - Starts from the position of opinionated software. That most use cases in web development are similar and we shouldn’t reinvent the wheel every time. Push Up a Big Tent - That said, the tool should support customization and the introduction of new tools if people prefer / have valid use cases. - Ex: RSpec over MiniTest / TestUnit More: http://rubyonrails.org/doctrine/
  • 11. _Why Ruby? - Dynamic With Ruby you can manipulate or modify the program you are running as it runs. Part of a concept known as metaprogramming.
  • 12.
  • 13. _Why Ruby? - Dynamically and Strongly Typed Dynamic Typing: A variable can change type to whatever you assign to it. Strong Typing: You cannot perform an action on a variable that doesn’t make sense for the current type.
  • 14.
  • 15.
  • 16. _Why Ruby? - Reflective You can inspect the characteristics of a class, method, variable at runtime. Combine this with the dynamic language features and dynamic typing and you can make decisions about what your code should be based on what your code currently is. How very zen
  • 17.
  • 18. There are no primitive types in Ruby. Literally everything you interact with is an object of some sort. A class, an instance of a class, etc. Contrast with .NET / Java / C where int, char, decimal and several others are primitives, not objects Main differences Primitives tend to be faster to interact with, pull out of memory and copy but immutable and inflexible. Objects are slower, more memory but far more flexible _Why Ruby? - Everything is an Object (Super OO)
  • 19.
  • 20. _Why Ruby? - Lack of Ceremony Ruby syntax tends to be clean(er) and devoid of most markers that other languages require like semicolons or parentheses At the same time ruby can support those things if preferred
  • 21.
  • 22. _Why Ruby? - Domain Specific Languages Ruby tools are usually written to be expressive and easy to read. They leverage a concept called DSL to describe the actions the tool can take. Ex: Rspec
  • 23.
  • 25. Ruby and Rails’ Impact - RubyGems One of the most comprehensive dependency management / library distribution tools anywhere at its release. Helped contribute to rise of social coding Inspired other platforms: NuGet (.NET), Composer (PHP), CocoaPods (Swift/Obj-C), NPM (Node.JS)
  • 26. Ruby and Rails’ Impact - Testing Flexibility of the language drove the rise in BDD and ATDD as a first class practice. Tools like: RSpec, Cucumber, Capybara, Watir Inspired other platforms: SpecFlow (.NET), Watin/Watij (.NET/Java), Jasmine (Javascript)
  • 27. Ruby and Rails’ Impact - Web MVC Rails implementation of a full-stack web framework designed around a Model View Controller architecture became the standard for framework design for about a decade. Just now starting to see a change to this with API driven, single page apps and functional programming. Inspired other platforms: ASP.Net MVC (.NET), Play (Java and Scala), Laravel / CodeIgniter (PHP)
  • 28. Ruby and Rails’ Impact - DevOps The DSL features of Rails helped spur the adoption of configurable operations tooling. It became easier to automate the setup of infrastructure and ultimately spawned an entire “new” category of IT. Examples: Chef / Puppet
  • 29. Ruby and Rails’ Impact - Opinionated Programming Rails “Convention over Configuration” mantra broke down some of the stigma associated with setting intelligent defaults in frameworks / tools. Now most platforms package with a preferred DBMS, View Layer, Emailing Tool, etc. even if they are customizable. Ex: ASP.Net MVC with Entity Framework

Editor's Notes

  1. Dates may be a bit off Started career in .net One day a friend told me about user groups, these strange places where programmers got together to nerd out about some language or technology they loved and he dragged me along to this tiny group called the Cleveland Ruby Brigade. It was on this beatup old restaurant boat on lake erie that this weird software company called Lean Dog had made home. I think twice during the meeting people came in asking if they were serving dinner that night. I think the topic was an overview of the latest version of Rails… something like 2.3 maybe at the time. Web development could be easy. .NET had alwasy been overly complicated and PHP, the language i used to work in, was ugly and hard to maintain. Some friends and I decided we would get into ruby in a crazy way, by staying up for 2 nights straight and competing in a hackathon. Rails Rumble. We lost but had so much fun working on the idea that I knew I needed to get a job building ruby apps.
  2. Introduction - Noticed quite a few new people - Why does this group exist? What drew a bunch of us to ruby and why do we meet every month to talk about a programming language? - End w/ discussion. Vets can talk about why they stick around, newbies can explain why they showed up. - Much of this talk is subjective / opinion, which is why I'm looking forward to the discussion part. I've tried to cite sources in a few places but generally treat this as an opinion piece
  3. .NET in 2002, Java in May ‘95 just a couple of months before Ruby More on language influences in a bit References: https://www.ruby-lang.org/en/about/ https://en.wikipedia.org/wiki/.NET_Framework https://en.wikipedia.org/wiki/Java_(programming_language)
  4. References: Inflection Point: https://www.ruby-lang.org/en/about/
  5. References: https://en.wikipedia.org/wiki/Why%27s_(poignant)_Guide_to_Ruby https://en.wikipedia.org/wiki/Jim_Weirich https://en.wikipedia.org/wiki/Merb
  6. References: https://www.ruby-lang.org/en/community/conferences/
  7. References: https://en.wikipedia.org/wiki/Principle_of_least_astonishment https://www.python.org/dev/peps/pep-0020/
  8. References: http://rubyonrails.org/doctrine/
  9. Apologies to _why Tied to but not the same as compiled vs interpreted. Dynamic languages run though many common tasks at run time like extending code. In ruby this happens in order of the interpreter encountering the code. References: http://ruby-metaprogramming.rubylearning.com/html/ruby_metaprogramming_2.html http://archive.oreilly.com/pub/post/what_is_a_dsl.html https://en.wikipedia.org/wiki/Smalltalk#Object-oriented_programming https://www.ruby-lang.org/en/about/ http://www.rubyfleebie.com/ruby-is-dynamically-and-strongly-typed/
  10. Reference: https://gist.github.com/matugm/db363c7131e6af27716c
  11. Apologies to _why References: http://ruby-metaprogramming.rubylearning.com/html/ruby_metaprogramming_2.html http://archive.oreilly.com/pub/post/what_is_a_dsl.html https://en.wikipedia.org/wiki/Smalltalk#Object-oriented_programming https://www.ruby-lang.org/en/about/ http://www.rubyfleebie.com/ruby-is-dynamically-and-strongly-typed/
  12. Reference: https://gist.github.com/matugm/db363c7131e6af27716c
  13. Reference: https://gist.github.com/matugm/db363c7131e6af27716c
  14. Apologies to _why References: http://ruby-metaprogramming.rubylearning.com/html/ruby_metaprogramming_2.html http://archive.oreilly.com/pub/post/what_is_a_dsl.html https://en.wikipedia.org/wiki/Smalltalk#Object-oriented_programming https://www.ruby-lang.org/en/about/ http://www.rubyfleebie.com/ruby-is-dynamically-and-strongly-typed/
  15. Reference: https://gist.github.com/matugm/db363c7131e6af27716c
  16. Apologies to _why For MRI this means everything is on the the heap Difference http://stackoverflow.com/questions/8643276/object-vs-primitive References: http://ruby-metaprogramming.rubylearning.com/html/ruby_metaprogramming_2.html http://archive.oreilly.com/pub/post/what_is_a_dsl.html https://en.wikipedia.org/wiki/Smalltalk#Object-oriented_programming https://www.ruby-lang.org/en/about/ http://www.rubyfleebie.com/ruby-is-dynamically-and-strongly-typed/
  17. Reference: https://gist.github.com/matugm/db363c7131e6af27716c
  18. Apologies to _why References: http://ruby-metaprogramming.rubylearning.com/html/ruby_metaprogramming_2.html http://archive.oreilly.com/pub/post/what_is_a_dsl.html https://en.wikipedia.org/wiki/Smalltalk#Object-oriented_programming https://www.ruby-lang.org/en/about/ http://www.rubyfleebie.com/ruby-is-dynamically-and-strongly-typed/
  19. This is a little unfair. The 2nd find implementation is unnecessary because AR does that. Also I’m introducing an entire repository to demonstrate how that pattern typically works in C# which isn’t really needed. Reference: https://gist.github.com/matugm/db363c7131e6af27716c
  20. Apologies to _why References: http://ruby-metaprogramming.rubylearning.com/html/ruby_metaprogramming_2.html http://archive.oreilly.com/pub/post/what_is_a_dsl.html https://en.wikipedia.org/wiki/Smalltalk#Object-oriented_programming https://www.ruby-lang.org/en/about/ http://www.rubyfleebie.com/ruby-is-dynamically-and-strongly-typed/
  21. Reference: https://gist.github.com/matugm/db363c7131e6af27716c
  22. Apologies to _why References: http://ruby-metaprogramming.rubylearning.com/html/ruby_metaprogramming_2.html http://archive.oreilly.com/pub/post/what_is_a_dsl.html https://en.wikipedia.org/wiki/Smalltalk#Object-oriented_programming https://www.ruby-lang.org/en/about/ http://www.rubyfleebie.com/ruby-is-dynamically-and-strongly-typed/