How to Get Started with Open Source
Sam Jarman π¨πΌβπ»
May 25 '17
This is the 6th post in my Junior Developer Diaries blog series. Iβm writing more every week, and you can sign up to hear more and read previous posts on my website.
As an employer, or even a fellow developer, I want to see your passion for this industry. One of the best ways to do this is to have some of your favourite projectsβs code open to view by me and others.
What is Open Source?
Open source is a term used to refer to codebases that anyone can view and propose edits to. Most notably for our industry is the website GitHub, which hosts almost all open source projects.
Open sourcing projects is a great way to get involved in the community β it lets you interact with other developers, it lets you learn to code better, and it even can help you become familiar with large code bases, something often quite daunting for junior developers.
How do you start?
But how do you start? First, Iβd try something really, really simple. Go find a project you like, maybe itβs your favourite ruby gem or or an npm package and start reading the code. Weβre not looking for logical flaws here, weβre looking for typos. Yes. Typos. Typos in comments. Your first pull request to an open source will be a typo correction. You will change reuturns to returns. You will change him to them. You will change whatever you can find that is trivial and safe.
But the change isnβt important. What is important is how you then propose the change. Look around a bit, and youβll most likely find a contributorβs guide or a section in the read me. These sections will tell you how you make a change to the code base. How you check out the code, run it, branch naming conventions, PR conventions etc. You might also want to read last weekβs Code Reviews blog for a good read on how to create a great PR. Also itβs a great time to interact with the maintainers of the project, and start that relationship that will be helpful to have as the intensity of the PRs increase.
Now that youβve learnt how forking and creating pull requests works, itβs time you open source something of your own. But what Sam? Well, do you have any projects from Uni or bootcamp? How about that script you wrote one weekend for a laugh? How about that code you wrote a hackathon?
The code doesnβt necessarily have to be good (whatever that means?!) just get it online. It doesnβt have to be finished. We just want to see youβve done something. And yes, you donβt have to get fancy and write a contributing guide like the one above, but a simple yet effective ReadMe will be helpful.
What a Great ReadMe Has
So what goes into a great ReadMe?
- A description of the project. What does it do? What does it solve?
- Installation of the code into your own, or how to run it on your computer
- Common (trivial) examples of usage
- Comments about how to contribute. This can be simple
- A link to more information, documentation or support
- A list of known bugs, limitations and/or a To Do list of features. Although these should also be issues in the GitHub repo
- Optionally, a list of people using this code inside theirs (in the case of plugins etc) or top contributors
- If no LICENSE.md, an indication of the license of the code (MIT, Apache etc). Use Choose a License to determine this
What a Great Repo Has
So thatβs a great open source ReadMe. What else should a great repo have (apart from code)? (Yes, I know, some of my projects donβt have all of these)
- A ReadMe
- A Contributing Guide
- An Issues template
- A PR template
- A License
- A Code of Conduct
So go on, set up your GitHub account (theyβre free). Learn the fundamentals and get started! Look at you go! Open sourcing is a really great way to get involved in this community and it will really help you grow your technical skills as a developer. I wish you the best of luck!
This is the 6th post in my Junior Developer Diaries blog series. Iβm writing more every week, and you can sign up to hear more and read previous posts on my website.
How to find Good First Issues to Contribute OSS
Masato Ohba - Jun 27
Module Monday: Parallax scroll, Image gallery, Sidenav, & more
Tyler Warnock - Jun 25
I'm an open source enthusiast at Mapbox, the creator of Leaflet and 40+ other JS libraries, and a rock musician. AMA!
Vladimir Agafonkin - Jun 25
Connecting a LoRa device to Wia via The Things Network
Austin Spivey - Jun 26
Vicky (VM) Brasseur on Open Source and Public Speaking
Dev Chats: Monica Dinculescu
Google Summer of Code - can any organizations help me contribute?
How to start learning React.js
Theodora: Starting an Open Source Project
Who's looking for open source contributors? (July 2 edition)
Learning from good open source projects
Module Monday: Carousel slideshow, Sticky footer, Phone overlay &Β more
48
12
Iβm working on a project to help beginners get started on contributing open source projects.Β github.com/Roshanjossey/first-cont...
Itβd be awesome if you could check it out and gimme feedback
Looks great, Roshan! Lovely idea!
Thanks mate. Please do share it to people who might find it useful
Wonderful post, you're more than welcome to post other parts of the series. π
Thanks Ben, that really means a lot coming from you :) I'll be posting the others very soon so more people can benefit from my writing! :)
Your link to an example CoC (or article about CoC) is just a hash link back to this article. If you happen to have a good link for this, please share. Glad you pointed out that a great repo should have a Code of Conduct. I think they're absolutely necessary.
Good spotting Anthony! Totally agree. I was meaning to link to this - help.github.com/articles/adding-a-...
Thanks!
Hey there, we see you aren't signed in. (Yes you, the reader. This is a fake comment.)
Please consider creating an account on dev.to. It literally takes a few seconds and we'd appreciate the support so much. β€οΈ
Plus, no fake comments when you're signed in. π
This is really the push I needed to get started. I've been meaning to put some very simple projects up on Github, to learn how it works and also to learn from anyone willing to contribute. Thank you very much for your post sir.
Alexandros, thank you so much for your comment. It's really motivating to hear this when Im working on this series. Thank you and good luck! <3
Sir,I have just studied HTML CSS Bootstrap and heading on to JS.I have no experience in the field.So can u give any sort of suggestions to me for starting my blog here at The Practical Dev or open source contributions.
Click that "Write a post" button on the top left and write what you've done so far. Tell your story.
Awesome post Sam and thanks for share it, you have give me all the information I need to get started in GitHub to contribute to Open Source. :)
Thanks Ruben! I appreciate the comment :)
Great post Sir. I'm sure this will help me as I begin my Javascript journeyπ.
Great write-up, Sam. You might have already seen, but GitHub just released the results of their OSS survey.
Thank you for the kind comment, Walker. Good link! Thank you :)
Great. I can recommend also this guide:
Open Source Guide
There is a typo in "What is important is how you the*m* propose the change." :)
Gosh, why do they put those keys so close together!?