SlideShare a Scribd company logo
1 of 65
Tweakers Anonymous
Tweakers Anonymous
       “John”
Tweakers Anonymous
  John SJ Anderson / @genehack / dc.pm
      YAPC::NA 2012 ~ Madison WI
An elegant
 weapon for a
more civilized age
Instead...
•   Not editor specific
•   Not so much “how”
•   More “what”
•   Applicable to any
    programmer’s editor
Programmer’s editor
Programmer’s editor

• Syntax highlighting
• Indentation support
• Some amount of programability
Syntax Highlighting
Syntax Highlighting

• Helps catch stuipd typos faster
Syntax Highlighting

• Helps catch stuipd typos faster
• Can obscure code
Syntax Highlighting

• Helps catch stuipd typos faster
• Can obscure code
• Figure out to toggle it off
Indentation Support
Well, then get one that does do auto-indent.
You can't do good work with bad tools.
  – Mark Jason Dominus's Good Advice #11918
Programmable
Programmable

• Doesn’t need to be Turing complete
Programmable

• Doesn’t need to be Turing complete
• Although that’s nice
Programmable

• Doesn’t need to be Turing complete
• Although that’s nice
• If you can select some text, send it to an
  external program, and get the output
  inserted back in, you’re good to go
Take-home message
Take-home message
• Pay some attention to what you’re doing
Take-home message
• Pay some attention to what you’re doing
• Configure your environment so that most
  frequently done stuff can be done easily
Take-home message
• Pay some attention to what you’re doing
• Configure your environment so that most
  frequently done stuff can be done easily
• The F keys on your keyboard are not just
  to skip tracks in your MP3 player
Take-home message
• Pay some attention to what you’re doing
• Configure your environment so that most
  frequently done stuff can be done easily
• The F keys on your keyboard are not just
  to skip tracks in your MP3 player
• Keep your configs in git – you will screw
  them up. This will save you.
Ever done this?
Ever done this?

$ vim my_awesome_script.pl
Ever done this?

$ vim my_awesome_script.pl
# hack hack hack ; :wq
Ever done this?

$ vim my_awesome_script.pl
# hack hack hack ; :wq
$ ./my_awesome_script.pl
Ever done this?

$ vim my_awesome_script.pl
# hack hack hack ; :wq
$ ./my_awesome_script.pl
bash: ./my_awesome_script.pl:
Permission denied
Fix your editor so this
 never happens again

autocmd BufWritePost *.pl !chmod +x %
(add-hook 'after-save-hook
 'executable-make-buffer-file-executable-if-script-p)
Commit messages
Commit messages
• Set up your revision control system so your
  commit messages are written in your
  preferred editor
Commit messages
• Set up your revision control system so your
  commit messages are written in your
  preferred editor
• $EDITOR, $VISUAL, $GIT_EDITOR, etc.
Commit messages
• Set up your revision control system so your
  commit messages are written in your
  preferred editor
• $EDITOR, $VISUAL, $GIT_EDITOR, etc.
• Vim users may enjoy a brief moment of
  smugness at this point in the talk
Commit messages
• Set up your revision control system so your
  commit messages are written in your
  preferred editor
• $EDITOR, $VISUAL, $GIT_EDITOR, etc.
• Vim users may enjoy a brief moment of
  smugness at this point in the talk
• Emacs users should look into
  emacsclient -t
Code Formatting &
     Tidying
Code Formatting &
       Tidying
• Same idea as “make executable on save”
Code Formatting &
       Tidying
• Same idea as “make executable on save”
• When you save a file, before it gets
  written, run perltidy on the file content
  and save the tidied version instead
Code Formatting &
        Tidying
• Same idea as “make executable on save”
• When you save a file, before it gets
  written, run perltidy on the file content
  and save the tidied version instead
• If you don’t want to do that, you can at
  least configure things like trailing
  whitespace removeal, de-tab/en-tab, etc.
Syntax Checking
Syntax Checking


• I have one trick and I use it everywhere
Syntax Checking


• I have one trick and I use it everywhere
• During file save, after the file is written out,
  run perl -c on it and display any errors
Even better:
Syntax checking on the fly
Ill-advised live demo!
Even more betterest:
   Syntax checking
  and static analysis
      on the fly
Even more ill-advised
      demo
Code and
documentation browsing
Code and
documentation browsing

• Emacs calls this find-file-at-point
Code and
documentation browsing

• Emacs calls this find-file-at-point
• ffap!
Code and
documentation browsing

• Emacs calls this find-file-at-point
• ffap!
• Vim uses ‘gf’ (goto-file)
Auto-complete
Auto-complete
•   Can’t be done perfectly
Auto-complete
•   Can’t be done perfectly
•   Can be done fairly well
Auto-complete
•   Can’t be done perfectly
•   Can be done fairly well
•   Takes a lot of effort, is very fragile, and probably
    isn’t worth it
Auto-complete
•   Can’t be done perfectly
•   Can be done fairly well
•   Takes a lot of effort, is very fragile, and probably
    isn’t worth it
•   Really all you need is “complete based on stuff
    in open files”
Auto-complete
•   Can’t be done perfectly
•   Can be done fairly well
•   Takes a lot of effort, is very fragile, and probably
    isn’t worth it
•   Really all you need is “complete based on stuff
    in open files”
•   If you’re at the point where you’re messing with
    this, you probably need to get back to work
The more subtle
take-home message
The more subtle
   take-home message
• 5% of us care about this stuff way too much
The more subtle
   take-home message
• 5% of us care about this stuff way too much
• 80% of us don’t care about it nearly enough
The more subtle
    take-home message
• 5% of us care about this stuff way too much
• 80% of us don’t care about it nearly enough
• If you’re not sure which group you fall into,
  you’re in the 80%
The more subtle
    take-home message
• 5% of us care about this stuff way too much
• 80% of us don’t care about it nearly enough
• If you’re not sure which group you fall into,
  you’re in the 80%
• 67% of statistics are made up to fill slide
  space
The more subtle
take-home message
The more subtle
    take-home message
• The editor is one of the tools you use the
  most when practicing your craft
The more subtle
    take-home message
• The editor is one of the tools you use the
  most when practicing your craft
• Spending some time to make it work better
  for you will let you work better too
The more subtle
    take-home message
• The editor is one of the tools you use the
  most when practicing your craft
• Spending some time to make it work better
  for you will let you work better too
• The less friction you have around frequent
  operations, the more chance you have to
  get into flow
Share & enjoy


• Emacs config: github.com/genehack/emacs
•   Vim config: github.com/genehack/genehack-vim
Thanks!
Questions?
Share & enjoy


• Emacs config: github.com/genehack/emacs
•   Vim config: github.com/genehack/genehack-vim

More Related Content

What's hot

Passion For Software
Passion For SoftwarePassion For Software
Passion For SoftwareSven Peters
 
One Fish, Two Fish, Red Fish, Dru-Fish - BADCamp Presentation on Conference ...
One Fish, Two Fish,  Red Fish, Dru-Fish - BADCamp Presentation on Conference ...One Fish, Two Fish,  Red Fish, Dru-Fish - BADCamp Presentation on Conference ...
One Fish, Two Fish, Red Fish, Dru-Fish - BADCamp Presentation on Conference ...Dustin Boeger
 
AT&T Hack-o-ween
AT&T Hack-o-weenAT&T Hack-o-ween
AT&T Hack-o-weenEd Donahue
 
Robust Web APIs with node.js and Express
Robust Web APIs with node.js and ExpressRobust Web APIs with node.js and Express
Robust Web APIs with node.js and ExpressKevin Griffin
 

What's hot (6)

Optimera STHLM 2011 - Mikael Berggren, Spotify
Optimera STHLM 2011 - Mikael Berggren, SpotifyOptimera STHLM 2011 - Mikael Berggren, Spotify
Optimera STHLM 2011 - Mikael Berggren, Spotify
 
Passion For Software
Passion For SoftwarePassion For Software
Passion For Software
 
One Fish, Two Fish, Red Fish, Dru-Fish - BADCamp Presentation on Conference ...
One Fish, Two Fish,  Red Fish, Dru-Fish - BADCamp Presentation on Conference ...One Fish, Two Fish,  Red Fish, Dru-Fish - BADCamp Presentation on Conference ...
One Fish, Two Fish, Red Fish, Dru-Fish - BADCamp Presentation on Conference ...
 
AT&T Hack-o-ween
AT&T Hack-o-weenAT&T Hack-o-ween
AT&T Hack-o-ween
 
Robust Web APIs with node.js and Express
Robust Web APIs with node.js and ExpressRobust Web APIs with node.js and Express
Robust Web APIs with node.js and Express
 
Component-first Applications
Component-first ApplicationsComponent-first Applications
Component-first Applications
 

Viewers also liked

Datos acomodacion
Datos acomodacionDatos acomodacion
Datos acomodacionharveyalra
 
This is my family...
This is my family...This is my family...
This is my family...Daisy
 
Pieces valuable
Pieces valuablePieces valuable
Pieces valuableDaisy
 
Tạp trí Internet Marketing Số 08 - Feb 2012
Tạp trí Internet Marketing Số 08 - Feb 2012Tạp trí Internet Marketing Số 08 - Feb 2012
Tạp trí Internet Marketing Số 08 - Feb 2012Nguyễn Văn Mạnh
 
Social Media Horror Stories - "What can go wrong?"
Social Media Horror Stories - "What can go wrong?"Social Media Horror Stories - "What can go wrong?"
Social Media Horror Stories - "What can go wrong?"Xplore - your web agency
 
Unsere Sponsormappe | Wohnportal-Graz.at
Unsere Sponsormappe | Wohnportal-Graz.atUnsere Sponsormappe | Wohnportal-Graz.at
Unsere Sponsormappe | Wohnportal-Graz.atWohnportal Graz
 
Foto12 krutova final
Foto12 krutova finalFoto12 krutova final
Foto12 krutova finalShaRouge
 
Consumo en Navidad
Consumo en Navidad Consumo en Navidad
Consumo en Navidad AnaOrtegaS
 
Converting your linux Box in security Gateway Part – 2 (Looking inside VPN)
Converting your linux Box in security Gateway Part – 2 (Looking inside VPN)Converting your linux Box in security Gateway Part – 2 (Looking inside VPN)
Converting your linux Box in security Gateway Part – 2 (Looking inside VPN)n|u - The Open Security Community
 
Devon Youth Opportunity/Capital Fund
Devon Youth Opportunity/Capital FundDevon Youth Opportunity/Capital Fund
Devon Youth Opportunity/Capital FundDiocese of Exeter
 
5. Awareness raising activities of the GIZ Soc Trang project
5. Awareness raising activities of the GIZ Soc Trang project5. Awareness raising activities of the GIZ Soc Trang project
5. Awareness raising activities of the GIZ Soc Trang projectLittle Daisy
 

Viewers also liked (12)

Datos acomodacion
Datos acomodacionDatos acomodacion
Datos acomodacion
 
This is my family...
This is my family...This is my family...
This is my family...
 
Pieces valuable
Pieces valuablePieces valuable
Pieces valuable
 
Tạp trí Internet Marketing Số 08 - Feb 2012
Tạp trí Internet Marketing Số 08 - Feb 2012Tạp trí Internet Marketing Số 08 - Feb 2012
Tạp trí Internet Marketing Số 08 - Feb 2012
 
Social Media Horror Stories - "What can go wrong?"
Social Media Horror Stories - "What can go wrong?"Social Media Horror Stories - "What can go wrong?"
Social Media Horror Stories - "What can go wrong?"
 
Unsere Sponsormappe | Wohnportal-Graz.at
Unsere Sponsormappe | Wohnportal-Graz.atUnsere Sponsormappe | Wohnportal-Graz.at
Unsere Sponsormappe | Wohnportal-Graz.at
 
Foto12 krutova final
Foto12 krutova finalFoto12 krutova final
Foto12 krutova final
 
Consumo en Navidad
Consumo en Navidad Consumo en Navidad
Consumo en Navidad
 
Biomas
BiomasBiomas
Biomas
 
Converting your linux Box in security Gateway Part – 2 (Looking inside VPN)
Converting your linux Box in security Gateway Part – 2 (Looking inside VPN)Converting your linux Box in security Gateway Part – 2 (Looking inside VPN)
Converting your linux Box in security Gateway Part – 2 (Looking inside VPN)
 
Devon Youth Opportunity/Capital Fund
Devon Youth Opportunity/Capital FundDevon Youth Opportunity/Capital Fund
Devon Youth Opportunity/Capital Fund
 
5. Awareness raising activities of the GIZ Soc Trang project
5. Awareness raising activities of the GIZ Soc Trang project5. Awareness raising activities of the GIZ Soc Trang project
5. Awareness raising activities of the GIZ Soc Trang project
 

Similar to Tweakers Anonymous

Effective text editing with vim
Effective text editing with vimEffective text editing with vim
Effective text editing with vimxprayc
 
Building reusable components with generics and protocols
Building reusable components with generics and protocolsBuilding reusable components with generics and protocols
Building reusable components with generics and protocolsDonny Wals
 
Community and Github: 7/27/2011
Community and Github: 7/27/2011Community and Github: 7/27/2011
Community and Github: 7/27/2011Andy Lester
 
Developing client themes for theme review for WordCamp Edmonton
Developing client themes for theme review for WordCamp EdmontonDeveloping client themes for theme review for WordCamp Edmonton
Developing client themes for theme review for WordCamp EdmontonCurtis McHale
 
Surviving a Hackathon and Beyond
Surviving a Hackathon and BeyondSurviving a Hackathon and Beyond
Surviving a Hackathon and Beyondimoneytech
 
How I Learned to Stop Worrying and Love Legacy Code.....
How I Learned to Stop Worrying and Love Legacy Code.....How I Learned to Stop Worrying and Love Legacy Code.....
How I Learned to Stop Worrying and Love Legacy Code.....Mike Harris
 
The business case for contributing code
The business case for contributing codeThe business case for contributing code
The business case for contributing codeZivtech, LLC
 
Make Your Team Flow
Make Your Team FlowMake Your Team Flow
Make Your Team FlowChad Moone
 
Intro to WordPress Plugins
Intro to WordPress PluginsIntro to WordPress Plugins
Intro to WordPress Pluginszamoose
 
Packaging is the Worst Way to Distribute Software, Except for Everything Else
Packaging is the Worst Way to Distribute Software, Except for Everything ElsePackaging is the Worst Way to Distribute Software, Except for Everything Else
Packaging is the Worst Way to Distribute Software, Except for Everything Elsemckern
 
Clean Code - 5
Clean Code - 5Clean Code - 5
Clean Code - 5Don Kim
 
Remote Working at Spry Fox
Remote Working at Spry FoxRemote Working at Spry Fox
Remote Working at Spry FoxAndrew Fray
 
Refactoring RIA Unleashed 2011
Refactoring RIA Unleashed 2011Refactoring RIA Unleashed 2011
Refactoring RIA Unleashed 2011Jesse Warden
 
'Intro to Infrastructure as Code' - DevOps Belfast
'Intro to Infrastructure as Code' - DevOps Belfast'Intro to Infrastructure as Code' - DevOps Belfast
'Intro to Infrastructure as Code' - DevOps BelfastJohn Fitzpatrick
 
How To Be A Real Developer In Two Easy Steps!
How To Be A Real Developer In Two Easy Steps!How To Be A Real Developer In Two Easy Steps!
How To Be A Real Developer In Two Easy Steps!northofnormal
 
Twiggy - let's get our widget on!
Twiggy - let's get our widget on!Twiggy - let's get our widget on!
Twiggy - let's get our widget on!Elliott Kember
 

Similar to Tweakers Anonymous (20)

Tweakers Anonymous
Tweakers AnonymousTweakers Anonymous
Tweakers Anonymous
 
Effective text editing with vim
Effective text editing with vimEffective text editing with vim
Effective text editing with vim
 
Message passing
Message passingMessage passing
Message passing
 
Building reusable components with generics and protocols
Building reusable components with generics and protocolsBuilding reusable components with generics and protocols
Building reusable components with generics and protocols
 
Community and Github: 7/27/2011
Community and Github: 7/27/2011Community and Github: 7/27/2011
Community and Github: 7/27/2011
 
Developing client themes for theme review for WordCamp Edmonton
Developing client themes for theme review for WordCamp EdmontonDeveloping client themes for theme review for WordCamp Edmonton
Developing client themes for theme review for WordCamp Edmonton
 
Surviving a Hackathon and Beyond
Surviving a Hackathon and BeyondSurviving a Hackathon and Beyond
Surviving a Hackathon and Beyond
 
How I Learned to Stop Worrying and Love Legacy Code.....
How I Learned to Stop Worrying and Love Legacy Code.....How I Learned to Stop Worrying and Love Legacy Code.....
How I Learned to Stop Worrying and Love Legacy Code.....
 
The business case for contributing code
The business case for contributing codeThe business case for contributing code
The business case for contributing code
 
Make Your Team Flow
Make Your Team FlowMake Your Team Flow
Make Your Team Flow
 
Intro to WordPress Plugins
Intro to WordPress PluginsIntro to WordPress Plugins
Intro to WordPress Plugins
 
Packaging is the Worst Way to Distribute Software, Except for Everything Else
Packaging is the Worst Way to Distribute Software, Except for Everything ElsePackaging is the Worst Way to Distribute Software, Except for Everything Else
Packaging is the Worst Way to Distribute Software, Except for Everything Else
 
Clean Code - 5
Clean Code - 5Clean Code - 5
Clean Code - 5
 
Why puppet? Why now?
Why puppet? Why now?Why puppet? Why now?
Why puppet? Why now?
 
Remote Working at Spry Fox
Remote Working at Spry FoxRemote Working at Spry Fox
Remote Working at Spry Fox
 
Refactoring RIA Unleashed 2011
Refactoring RIA Unleashed 2011Refactoring RIA Unleashed 2011
Refactoring RIA Unleashed 2011
 
Bug Hunting Safari
Bug Hunting SafariBug Hunting Safari
Bug Hunting Safari
 
'Intro to Infrastructure as Code' - DevOps Belfast
'Intro to Infrastructure as Code' - DevOps Belfast'Intro to Infrastructure as Code' - DevOps Belfast
'Intro to Infrastructure as Code' - DevOps Belfast
 
How To Be A Real Developer In Two Easy Steps!
How To Be A Real Developer In Two Easy Steps!How To Be A Real Developer In Two Easy Steps!
How To Be A Real Developer In Two Easy Steps!
 
Twiggy - let's get our widget on!
Twiggy - let's get our widget on!Twiggy - let's get our widget on!
Twiggy - let's get our widget on!
 

More from John Anderson

Introduction to Git (even for non-developers)
Introduction to Git (even for non-developers)Introduction to Git (even for non-developers)
Introduction to Git (even for non-developers)John Anderson
 
Logs are-magic-devfestweekend2018
Logs are-magic-devfestweekend2018Logs are-magic-devfestweekend2018
Logs are-magic-devfestweekend2018John Anderson
 
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To YouLogs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To YouJohn Anderson
 
A static site generator should be your next language learning project
A static site generator should be your next language learning projectA static site generator should be your next language learning project
A static site generator should be your next language learning projectJohn Anderson
 
Do you want to be right or do you want to WIN?
Do you want to be right or do you want to WIN?Do you want to be right or do you want to WIN?
Do you want to be right or do you want to WIN?John Anderson
 
An Introduction to Git (even for non-developers)
An Introduction to Git (even for non-developers)An Introduction to Git (even for non-developers)
An Introduction to Git (even for non-developers)John Anderson
 
You got chocolate in my peanut butter! .NET on Mac & Linux
You got chocolate in my peanut butter! .NET on Mac & LinuxYou got chocolate in my peanut butter! .NET on Mac & Linux
You got chocolate in my peanut butter! .NET on Mac & LinuxJohn Anderson
 
A static site generator should be your next language learning project
A static site generator should be your next language learning projectA static site generator should be your next language learning project
A static site generator should be your next language learning projectJohn Anderson
 
Old Dogs & New Tricks: What's New with Perl5 This Century
Old Dogs & New Tricks: What's New with Perl5 This CenturyOld Dogs & New Tricks: What's New with Perl5 This Century
Old Dogs & New Tricks: What's New with Perl5 This CenturyJohn Anderson
 
Introduction to Git (even for non-developers!)
Introduction to Git (even for non-developers!)Introduction to Git (even for non-developers!)
Introduction to Git (even for non-developers!)John Anderson
 
Introduction to Git for Non-Developers
Introduction to Git for Non-DevelopersIntroduction to Git for Non-Developers
Introduction to Git for Non-DevelopersJohn Anderson
 
A Modest Introduction To Swift
A Modest Introduction To SwiftA Modest Introduction To Swift
A Modest Introduction To SwiftJohn Anderson
 
A static site generator should be your next language learning project
A static site generator should be your next language learning projectA static site generator should be your next language learning project
A static site generator should be your next language learning projectJohn Anderson
 
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To YouLogs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To YouJohn Anderson
 
JSON Web Tokens Will Improve Your Life
JSON Web Tokens Will Improve Your LifeJSON Web Tokens Will Improve Your Life
JSON Web Tokens Will Improve Your LifeJohn Anderson
 
Old Dogs & New Tricks: What's New With Perl5 This Century
Old Dogs & New Tricks: What's New With Perl5 This CenturyOld Dogs & New Tricks: What's New With Perl5 This Century
Old Dogs & New Tricks: What's New With Perl5 This CenturyJohn Anderson
 
A Modest Introduction to Swift
A Modest Introduction to SwiftA Modest Introduction to Swift
A Modest Introduction to SwiftJohn Anderson
 
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To YouLogs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To YouJohn Anderson
 
Friends Don't Let Friends Browse Unencrypted: Running a VPN for friends and f...
Friends Don't Let Friends Browse Unencrypted: Running a VPN for friends and f...Friends Don't Let Friends Browse Unencrypted: Running a VPN for friends and f...
Friends Don't Let Friends Browse Unencrypted: Running a VPN for friends and f...John Anderson
 

More from John Anderson (20)

#speakerlife
#speakerlife#speakerlife
#speakerlife
 
Introduction to Git (even for non-developers)
Introduction to Git (even for non-developers)Introduction to Git (even for non-developers)
Introduction to Git (even for non-developers)
 
Logs are-magic-devfestweekend2018
Logs are-magic-devfestweekend2018Logs are-magic-devfestweekend2018
Logs are-magic-devfestweekend2018
 
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To YouLogs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
 
A static site generator should be your next language learning project
A static site generator should be your next language learning projectA static site generator should be your next language learning project
A static site generator should be your next language learning project
 
Do you want to be right or do you want to WIN?
Do you want to be right or do you want to WIN?Do you want to be right or do you want to WIN?
Do you want to be right or do you want to WIN?
 
An Introduction to Git (even for non-developers)
An Introduction to Git (even for non-developers)An Introduction to Git (even for non-developers)
An Introduction to Git (even for non-developers)
 
You got chocolate in my peanut butter! .NET on Mac & Linux
You got chocolate in my peanut butter! .NET on Mac & LinuxYou got chocolate in my peanut butter! .NET on Mac & Linux
You got chocolate in my peanut butter! .NET on Mac & Linux
 
A static site generator should be your next language learning project
A static site generator should be your next language learning projectA static site generator should be your next language learning project
A static site generator should be your next language learning project
 
Old Dogs & New Tricks: What's New with Perl5 This Century
Old Dogs & New Tricks: What's New with Perl5 This CenturyOld Dogs & New Tricks: What's New with Perl5 This Century
Old Dogs & New Tricks: What's New with Perl5 This Century
 
Introduction to Git (even for non-developers!)
Introduction to Git (even for non-developers!)Introduction to Git (even for non-developers!)
Introduction to Git (even for non-developers!)
 
Introduction to Git for Non-Developers
Introduction to Git for Non-DevelopersIntroduction to Git for Non-Developers
Introduction to Git for Non-Developers
 
A Modest Introduction To Swift
A Modest Introduction To SwiftA Modest Introduction To Swift
A Modest Introduction To Swift
 
A static site generator should be your next language learning project
A static site generator should be your next language learning projectA static site generator should be your next language learning project
A static site generator should be your next language learning project
 
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To YouLogs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
 
JSON Web Tokens Will Improve Your Life
JSON Web Tokens Will Improve Your LifeJSON Web Tokens Will Improve Your Life
JSON Web Tokens Will Improve Your Life
 
Old Dogs & New Tricks: What's New With Perl5 This Century
Old Dogs & New Tricks: What's New With Perl5 This CenturyOld Dogs & New Tricks: What's New With Perl5 This Century
Old Dogs & New Tricks: What's New With Perl5 This Century
 
A Modest Introduction to Swift
A Modest Introduction to SwiftA Modest Introduction to Swift
A Modest Introduction to Swift
 
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To YouLogs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
Logs Are Magic: Why Git Workflows and Commit Structure Should Matter To You
 
Friends Don't Let Friends Browse Unencrypted: Running a VPN for friends and f...
Friends Don't Let Friends Browse Unencrypted: Running a VPN for friends and f...Friends Don't Let Friends Browse Unencrypted: Running a VPN for friends and f...
Friends Don't Let Friends Browse Unencrypted: Running a VPN for friends and f...
 

Recently uploaded

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
 
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
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
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 MenDelhi Call girls
 
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 Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
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
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
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
 

Recently uploaded (20)

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
 
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
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
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
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
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
 
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptxVulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
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
 

Tweakers Anonymous

  • 2. Tweakers Anonymous “John”
  • 3. Tweakers Anonymous John SJ Anderson / @genehack / dc.pm YAPC::NA 2012 ~ Madison WI
  • 4. An elegant weapon for a more civilized age
  • 5. Instead... • Not editor specific • Not so much “how” • More “what” • Applicable to any programmer’s editor
  • 7. Programmer’s editor • Syntax highlighting • Indentation support • Some amount of programability
  • 9. Syntax Highlighting • Helps catch stuipd typos faster
  • 10. Syntax Highlighting • Helps catch stuipd typos faster • Can obscure code
  • 11. Syntax Highlighting • Helps catch stuipd typos faster • Can obscure code • Figure out to toggle it off
  • 12. Indentation Support Well, then get one that does do auto-indent. You can't do good work with bad tools. – Mark Jason Dominus's Good Advice #11918
  • 14. Programmable • Doesn’t need to be Turing complete
  • 15. Programmable • Doesn’t need to be Turing complete • Although that’s nice
  • 16. Programmable • Doesn’t need to be Turing complete • Although that’s nice • If you can select some text, send it to an external program, and get the output inserted back in, you’re good to go
  • 18. Take-home message • Pay some attention to what you’re doing
  • 19. Take-home message • Pay some attention to what you’re doing • Configure your environment so that most frequently done stuff can be done easily
  • 20. Take-home message • Pay some attention to what you’re doing • Configure your environment so that most frequently done stuff can be done easily • The F keys on your keyboard are not just to skip tracks in your MP3 player
  • 21. Take-home message • Pay some attention to what you’re doing • Configure your environment so that most frequently done stuff can be done easily • The F keys on your keyboard are not just to skip tracks in your MP3 player • Keep your configs in git – you will screw them up. This will save you.
  • 23. Ever done this? $ vim my_awesome_script.pl
  • 24. Ever done this? $ vim my_awesome_script.pl # hack hack hack ; :wq
  • 25. Ever done this? $ vim my_awesome_script.pl # hack hack hack ; :wq $ ./my_awesome_script.pl
  • 26. Ever done this? $ vim my_awesome_script.pl # hack hack hack ; :wq $ ./my_awesome_script.pl bash: ./my_awesome_script.pl: Permission denied
  • 27. Fix your editor so this never happens again autocmd BufWritePost *.pl !chmod +x % (add-hook 'after-save-hook 'executable-make-buffer-file-executable-if-script-p)
  • 29. Commit messages • Set up your revision control system so your commit messages are written in your preferred editor
  • 30. Commit messages • Set up your revision control system so your commit messages are written in your preferred editor • $EDITOR, $VISUAL, $GIT_EDITOR, etc.
  • 31. Commit messages • Set up your revision control system so your commit messages are written in your preferred editor • $EDITOR, $VISUAL, $GIT_EDITOR, etc. • Vim users may enjoy a brief moment of smugness at this point in the talk
  • 32. Commit messages • Set up your revision control system so your commit messages are written in your preferred editor • $EDITOR, $VISUAL, $GIT_EDITOR, etc. • Vim users may enjoy a brief moment of smugness at this point in the talk • Emacs users should look into emacsclient -t
  • 33. Code Formatting & Tidying
  • 34. Code Formatting & Tidying • Same idea as “make executable on save”
  • 35. Code Formatting & Tidying • Same idea as “make executable on save” • When you save a file, before it gets written, run perltidy on the file content and save the tidied version instead
  • 36. Code Formatting & Tidying • Same idea as “make executable on save” • When you save a file, before it gets written, run perltidy on the file content and save the tidied version instead • If you don’t want to do that, you can at least configure things like trailing whitespace removeal, de-tab/en-tab, etc.
  • 38. Syntax Checking • I have one trick and I use it everywhere
  • 39. Syntax Checking • I have one trick and I use it everywhere • During file save, after the file is written out, run perl -c on it and display any errors
  • 42. Even more betterest: Syntax checking and static analysis on the fly
  • 45. Code and documentation browsing • Emacs calls this find-file-at-point
  • 46. Code and documentation browsing • Emacs calls this find-file-at-point • ffap!
  • 47. Code and documentation browsing • Emacs calls this find-file-at-point • ffap! • Vim uses ‘gf’ (goto-file)
  • 49. Auto-complete • Can’t be done perfectly
  • 50. Auto-complete • Can’t be done perfectly • Can be done fairly well
  • 51. Auto-complete • Can’t be done perfectly • Can be done fairly well • Takes a lot of effort, is very fragile, and probably isn’t worth it
  • 52. Auto-complete • Can’t be done perfectly • Can be done fairly well • Takes a lot of effort, is very fragile, and probably isn’t worth it • Really all you need is “complete based on stuff in open files”
  • 53. Auto-complete • Can’t be done perfectly • Can be done fairly well • Takes a lot of effort, is very fragile, and probably isn’t worth it • Really all you need is “complete based on stuff in open files” • If you’re at the point where you’re messing with this, you probably need to get back to work
  • 55. The more subtle take-home message • 5% of us care about this stuff way too much
  • 56. The more subtle take-home message • 5% of us care about this stuff way too much • 80% of us don’t care about it nearly enough
  • 57. The more subtle take-home message • 5% of us care about this stuff way too much • 80% of us don’t care about it nearly enough • If you’re not sure which group you fall into, you’re in the 80%
  • 58. The more subtle take-home message • 5% of us care about this stuff way too much • 80% of us don’t care about it nearly enough • If you’re not sure which group you fall into, you’re in the 80% • 67% of statistics are made up to fill slide space
  • 60. The more subtle take-home message • The editor is one of the tools you use the most when practicing your craft
  • 61. The more subtle take-home message • The editor is one of the tools you use the most when practicing your craft • Spending some time to make it work better for you will let you work better too
  • 62. The more subtle take-home message • The editor is one of the tools you use the most when practicing your craft • Spending some time to make it work better for you will let you work better too • The less friction you have around frequent operations, the more chance you have to get into flow
  • 63. Share & enjoy • Emacs config: github.com/genehack/emacs • Vim config: github.com/genehack/genehack-vim
  • 65. Share & enjoy • Emacs config: github.com/genehack/emacs • Vim config: github.com/genehack/genehack-vim

Editor's Notes

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. \n
  26. \n
  27. \n
  28. \n
  29. \n
  30. \n
  31. \n
  32. \n
  33. \n
  34. \n
  35. \n
  36. \n
  37. \n
  38. \n
  39. \n
  40. \n
  41. \n
  42. \n
  43. \n
  44. \n
  45. \n
  46. \n
  47. \n
  48. \n
  49. \n
  50. \n
  51. \n
  52. \n