Top Banner
Being an Open Source Contributor Mike Lively
38

Contributing to Open Source Software

Apr 15, 2017

Download

Software

Mike Lively
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Contributing to Open Source Software

Being an Open Source Contributor

Mike Lively

Page 2: Contributing to Open Source Software

Mike Lively• PHPUnit Database

Extension

• Phake - PHP Mocking Framework

• Lots of other small OSS contributions

• Manager of Software Architecture @ slickdeals.net

Page 3: Contributing to Open Source Software

Why are you here?• I contribute already, just curious how

others do it• I don’t contribute yet and want to know

how to get started• Not sure if I want to contribute ever, but

still interested in how it all works

Page 4: Contributing to Open Source Software

Why are you here?

• I’m just waiting for your talk to finish up so I can hear about PHP 7

Page 5: Contributing to Open Source Software

Contributing to OSS• Why contribute to OSS?• Contribute vs. Create• How to Contribute• How to Create• The cool tools

Page 6: Contributing to Open Source Software

Why should I Contribute?

• Give back a great idea• Learn something new• Get better at what you know• Improve your resume

Page 7: Contributing to Open Source Software

Why should I Contribute?

• Phase 1: Start an open source project• Phase 2: ???• Phase 3: Profit ($$$)

Page 8: Contributing to Open Source Software

Contribute or Create?

Page 9: Contributing to Open Source Software

Create a new project when…

• You have a new idea• You have a new take on an existing idea• You have lots of time to spare

Page 10: Contributing to Open Source Software

Contribute to an existing project when…

• you are looking to learn something new• you are looking to improve your resume• want to be involved in OSS but don’t have

any ideas• Because you are a nice person

Page 11: Contributing to Open Source Software

Contributing to Projects

Do it because

Page 12: Contributing to Open Source Software

How to Contribute to Projects

• Submit Pull Requests, not issues• Be a team player, follow their style• Be brave, large popular projects need help

too• Get involved with a community• Check your ego at the door

Page 13: Contributing to Open Source Software

Creating an OSS Project

A successful open source project at its core will offer the same thing most successful businesses offer: value

to a community that to that point has not had that value available.

Page 14: Contributing to Open Source Software

Defining Project Success

For the purposes of this talk, success is providing a project to the community that is able to outlast your own contributions.

Page 15: Contributing to Open Source Software

How to Create a Successful Project

• Make your project unique• License appropriately• Document Well• Provide an environment that encourages

community

Page 16: Contributing to Open Source Software

Make your Project Unique

• A new and novel idea• Already exists, but outside of a particular

community• Already exists inside the community but

unique value is provided

Page 17: Contributing to Open Source Software

Picking a License

Page 18: Contributing to Open Source Software

Pick the right license

• Dictates who will use your project• Increasingly important for larger companies• Provides protection for yourself

Page 19: Contributing to Open Source Software

Pick the right license

• GPL - A copyleft license. Limits corporate adoption

• MIT - grants free, unrestricted use• BSD - Similar to MIT + disallows use of your

name

Page 20: Contributing to Open Source Software

What to look for• Clear rights granted for copy, modification,

distribution, etc.• Requirements are attached to those rights• Clear “provided as-is” terms• Non-endorsement clauses (if desired)

Page 21: Contributing to Open Source Software

What to look for

Just use a common, well understood license

http://opensource.org/licenses

Page 22: Contributing to Open Source Software

CLA

• Contributor License Agreement• Helps ensure you either have copyright or

granted right• Highly recommended if you have future

plans to profit from the project

Page 23: Contributing to Open Source Software

CLA• Grants the project owner rights to the

contribution• Easiest to just be granted the copyright• Otherwise get as broad of a range of rights• To sign over rights, the contributor must be

the owner of the rights

Page 24: Contributing to Open Source Software

CCLA

• Corporate Contributor License Agreement• Used to gain authorization from a

contributor’s employer• Same principles apply

Page 25: Contributing to Open Source Software

CLA/CCLA

http://oss-watch.ac.uk/resources/cla

Page 26: Contributing to Open Source Software

Document Well• Focus documentation

efforts towards your goal

• Adoption? Document usage

• Contributions? Document code and architecture

Page 27: Contributing to Open Source Software

Document Well

• More than just Manuals• Articles, Tutorials, and

more • Don’t stop documenting

Page 28: Contributing to Open Source Software

Document Well

• Keep manuals close to code• Keep articles, tutorials, blog posts well

linked• Create a site for your project

Page 29: Contributing to Open Source Software

Document Well

A horrible library with great documentation will get more use

than a great library with no documentation.

Page 30: Contributing to Open Source Software

Encourage Community

Page 31: Contributing to Open Source Software

–Linus Torvalds

“In open source, we feel strongly that to really do something well, you have to

get a lot of people involved.”

Page 32: Contributing to Open Source Software

Encourage Community

• You are the community in the beginning• Write articles, blog posts, tutorials

whenever possible• Provide guidelines for code contributions• Get others involved quickly

Page 33: Contributing to Open Source Software

Encourage Community

• Address issues, pull requests, etc.• Make people feel appreciated for

contributions• Strengthening the community trumps

“integrity” of the code

Page 34: Contributing to Open Source Software

–Rasmus Lerdorf

“If you want to build an open source project, you can't let your ego stand in the way. You can't rewrite everybody's

patches, you can't second-guess everybody, and you have to give people

equal control.”

Page 35: Contributing to Open Source Software

Project Success Revisited

For the purposes of this talk, success is providing a project to the community that is able to outlast your own contributions.

Page 36: Contributing to Open Source Software

Encourage Community

• Look for your replacement• If your community begins forming strong

opinions, you are set.

Page 37: Contributing to Open Source Software

Tools I use• Revision Control: https://github.com/ • Release Distribution: https://packagist.org/ • Documentation: https://readthedocs.org/ • Continuous Testing: https://travis-ci.org/• Code Quality: https://scrutinizer-ci.com/• Code Quality 2: https://codeclimate.com/ • Dependency Management:

https://www.versioneye.com/

Page 38: Contributing to Open Source Software

Thanks• Buy my book ————->

http://goo.gl/zVe3oP

• Go to my website:http://digitalsandwich.com

• Slides are posted: http://www.slideshare.net/mjlivelyjr