Why you should think twice about contributing to Open Source
Tags: opensource, beginners, productivity, motivation
Published: 2019-08-22 05:01:18

#### 7 out of 10 developers contribute to open source and here are some tips and suggestions on how to get started

It’s no secret that Open Source contribution is one of the most sought after skills in tech. In addition to the employment benefits, there are other advantages such as

- Learning and sharing knowledge
- Build and improve your brand’s visibility
- Collaboration and communication with other developers through code reviews and discussions
- Giving back to the community ❤
- Connect with like minded people, find your employee/employees, co-founder, mentor, mentee

According to [Eclipse Foundation](https://www.eclipse.org/org/value/public/pdf/business_of_open_source_infographic.pdf), Open Source has seen massive investment in recent years.

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/y8rui3bkrne1nfma5soq.png)


---

## Why should you care?
Looking back to the 2016 StackOverflow [survey](https://insights.stackoverflow.com/survey/2016), there is no mention of open source at all however, in 2017 [survey](https://insights.stackoverflow.com/survey/2017#developer-profile-_-program-as-a-hobby) around 32.7% of respondents claimed to contribute to open source and this figure increased by nearly 10% (to 43.6%) in 2018 [survey](https://insights.stackoverflow.com/survey/2018#developer-profile-_-contributing-to-open-source) and what is even more interesting is that the % of contributors rose by 20% in 2019 (to 63.3%).

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/dbp1y5ldgdz7zryq2twn.png)

According to a [2016 Future of Open Source Survey Results](https://www.slideshare.net/blackducksoftware/2016-future-of-open-source-survey-results) by BlackDuck around 67% of participation in open source has been to

- Fix bugs 
- Add new features 

> 59% of developers participate in open source to gain competitive edge.

Taking into account the above facts, figures and trends, IMO it’s worth considering open source contribution.

> Be the change that you wish to see in the world — Mahatma Gandhi

---

## Reasons why I failed to contribute earlier?

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/8as7cvdt68tvjdfkv78c.png)

A majority of us developers love to contribute to open source but, we end up failing to do so for a variety of reasons. Here is a listing of reasons for me

- A majority of educational institutions neither recognize open source contribution as an effective way to learn nor motivate the students to participate — IMO, open source contribution should be part of the curriculum (as assignment, project, etc).

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/gqc3lz7ysjdu1wiixjvn.png)

- Your geographical location — IMO the country you live in also plays a vital role as highlighted in this [article](https://medium.com/@hoffa/github-top-countries-201608-13f642493773).
- New year resolution & birthday promises — I have had countless of these but, they never really worked.
- Unrealistic goals — I once decided that I will do at least twenty (20) pull requests to repository such as docker (because I ❤ docker) without taking into account the fact that I did not have the adequate knowledge to do so.
- Job, side projects and life excuses — Following every failure to contribute, I would consult myself that I am doing well in other verticals.

> No matter how small the contribution, if you do it on a regular basis it does make a difference in the long run.

- Underestimating my abilities — At times I have looked into existing pull requests and issues and arrived to the conclusion that “This is complex”.
- Ignoring documentation issues — A majority times I have ignored all the documentation related issues.

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/vsximhkc1icnwrdai644.png)

- My employers didn't care — I would love a job that requires contributing back to the open source community.

- Procrastination — Definitely a factor for a variety of reasons.

These are some of the main reasons that stopped me from getting started with open source contribution early on.

--- 

## My Motivation

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/xho5d7auiam9pg86prqq.jpeg)

> The main motivation to contribute to open source for me was to become knowledgeable enough to write about it.

I have a strong emphasis on knowledge sharing and this is something that I try to do both personally as well as at work in team and organisation level.

I was working on a side project last year and I learned a few things about encryption, so I wrote about it [here](https://medium.com/@rhamedy/encryption-decryption-of-data-based-on-users-password-using-pbkdf2-aes-algorithms-592f8c1bb79a). Few months down the road, I helped write our company’s coding guidelines and used the knowledge to write an [article](https://medium.com/@rhamedy/a-short-summary-of-java-coding-best-practices-31283d0167d3) about it as well.

After two articles, I wanted to write about something that I regarded as really important for new devs and students ([Medium](https://medium.com/@rhamedy/key-habits-and-things-i-wish-i-knew-earlier-as-a-developer-43c9466a0407) version, not metered).

{% link https://dev.to/rhamedy/key-habits-and-things-i-wish-i-knew-earlier-as-a-developer-2c97 %} 


The community loved ❤ the article and received around ~50K views, many thousand claps and comments of appreciation (In Medium - prior to their Paywall).

The next big article for me was to write about open source contribution (this article) and for that I needed to make a few open source contributions first.

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/93e60jvsmvo6mkxvb3na.jpeg)

So if you find yourself in the same boat of wanting to contribute and have not yet then, look for that one reason, motivation, purpose, drive, whatever it is.

--- 

## My Contribution Strategy
I decided that I will contribute to a [Spring Framework](https://spring.io/), a library that I have used before. I was reading the **Contribution Guidelines** when I noticed a few broken links so, I created a [pull request](https://github.com/spring-projects/spring-security/pull/6522) to fix them.

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/g17nzm298uq75q0erwo7.png)

The pull request got merged and it felt so good that I decided to keep going however, there was a problem. A majority of GitHub issues (i.e. bugs, first-timer, help-needed, feature) would get picked by other contributors before I even have a chance to express interest.

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/hlabdu1xuujmupyz0r8n.jpeg)

> Whenever a process does not produce the desired result for me, I make a change and re-evaluate the results and continue this way until the results are desirable.

Here is what I did

- I subscribed (watched) to the Spring repository
- On my way to work, I would browse through email notifications and show interest via comment on issues that I could tackle

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/iiu0vagteobm1ldnj97x.png)

As a result of this strategy, I had a pool of issues to work on. The first enhancement [feature](https://github.com/spring-projects/spring-security/issues/4187)

{% github https://github.com/spring-projects/spring-security/issues/4187 %}

and the pull request for it 

{% github https://github.com/spring-projects/spring-security/pull/6550 %}

I continued in this fashion on a few other issues of type enhancement, bugs and new features resulting in the following PRs

- [Add placeholder support for header tag attributes](https://github.com/spring-projects/spring-security/pull/6623) — **Spring Security**
- [Add configuration properties for remaining Undertow](https://github.com/spring-projects/spring-boot/pull/16278) — **Spring Boot**
- [Ensure Qualifier with bean name is evaluated when using SpyBean](https://github.com/spring-projects/spring-boot/pull/16331) — **Spring Boot** — Declined
- [Convert PluginPropertiesExtension Groovy to Java](https://github.com/elastic/elasticsearch/pull/39605) — **ElasticSearch**
- [Added Support for RFC 8414 OAuth 2.0 Authorization Server Metadata](https://github.com/spring-projects/spring-security/pull/6765) — **Spring Security**

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/vrnoqqat31esp5f11sg5.png)


So, if you are struggling to find issues to work on, pivot to a different strategy.

--- 

## Tips and Suggestions
Based on my knowledge and experience so far

- Participate in [Hacktoberfest](https://hacktoberfest.digitalocean.com/)
- A must-read [guide](https://opensource.guide/how-to-contribute/) on “how to contribute”
- Learn Git basics
- Pick a language i.e. Java, JavaScript
- Identify repositories that welcome contributions — Use tools such as [CodeTriage](https://www.codetriage.com/), [Github Explorer](https://github.com/explore/) and [this](https://firstcontributions.github.io/)
- Read the repository policies i.e. contribution guidelines
- Learn the project you want to contribute to
- Contribute in the form of code, documentation, bugs, and new features
- Filter issues based on labels such as help-needed, bug, first-timers, etc.
- Be mindful of others time specially maintainers who help you
- Ensure you have the necessary skills and time to invest
- Follow the discussions in issues and pull requests, see the code changes
- **Be patient and open to feedback**

I picked an Elastic Search [issue](https://github.com/elastic/elasticsearch/pull/39605) and **ignored** the fact that I needed to know some Groovy and how Elastic Search build worked as a consequence I spent a lot more time and effort in getting the PR to completion stage.

It’s always a good idea to do some research before opting to work on an issue.


---

## Recommended Reading
I would highly encourage you to read the open source [guide](https://opensource.guide/how-to-contribute/), and this [article](https://www.freecodecamp.org/news/the-definitive-guide-to-contributing-to-open-source-900d5f9f2282/) that comes with a wealth of knowledge on how to get started. This [article](https://medium.com/mindsdb/contributing-to-an-open-source-project-how-to-get-started-6ba812301738) highlights some good tips and if you are a visual person then these [videos](https://egghead.io/courses/how-to-contribute-to-an-open-source-project-on-github) by Kent C. Dodds might be helpful.

I saw this article on [Open Source Contribution](https://dev.to/integerman/how-to-contribute-to-open-source-software-4pbl) on Jan 27, 2020 and find it to be a helpful and relevant read.

--- 

Thank you for reading. Please feel free to follow me on here for more articles, connect on [LinkedIn](https://www.linkedin.com/in/rhamedy/) and other social media platforms of your choice.

If this article in any manner helped you in making your first contribution, then you are welcome to share your ideas, suggestions, feedback and pull request as a comment.