DEV Community

Cover image for An unexpected contribution to opensource and how it happened
Mo'men El-Zeiny
Mo'men El-Zeiny

Posted on

An unexpected contribution to opensource and how it happened

How it all started

I had been struggling for a few weeks trying to develop a habit of contributing to open source code. I once got my self to clone a repository but I stopped after building the dependencies and this was as far as I ever got. However, the idea always haunted me, I want to contribute to opensource.

The reason behind wanting to do this is because I think it has countless benefits, from knowledge transfer to identity branding and many others, however this is not the focus of this article.

An unexpected change

It was 11:30 PM that night, for some reason I ended up on GitHub exploring projects and I came across a project that looked familiar. It was one that I had cloned before and tried to work on some of it's issues. I suddenly felt different, I felt motivated, I felt that things are going to change. I was more determined than ever to end that night with something, something that can put me to sleep knowing that I've made a difference.

That night ended differently, I went for the kill, I submitted my first pull request.

What I did

STEP 1: I chose a programming language
This step was honestly easy for me, for quite a while I've wanted to pickup a new language and one that caught my interest was Go, a multipurpose system focused programming language which is fairly simple to grasp. Also bearing in mind, a while ago I had some free time, so I practiced the language by doing some algorithms. Therefore picking Go was an easy decision to make.

STEP 2: I found a beginner friendly project

One quick Google search and poof!

google search screenshot

The second result landed me on an awesome repository with a list of beginner friendly projects, which is also categorized by programming languages.

The repository I ended up choosing was mattermost-server one of the code bases managed by Mattermost

a flexible, open source messaging platform that enables secure team collaboration

Mattermost in a nutshell is Slack's opensource alternative, it's very active and has a solid community around it.

STEP 3: I was not overwhelmed and I found a starting point

This is the hardest I believe, finding the starting point, the issue that you can understand, a piece of the code that you can actually make a difference and contribute to. It's not easy to find that starting point, but it's doable. You just need to not get overwhelmed by the code base and focus on the smallest issue that you can do. I think that even a rename or replace old API kind of issue would make you more familiar with the code base and make you more confident and more ready for another contribution.

I started looking for the easiest issues, sorting them by issue tags that the Mattermost community uses to make it easier for beginners to do their first contribution. However, unfortunately most of the easy ones were taken, but I didn't lose hope I kept looking until I found my golden ticket, a help wanted issue.

Community asking for help on plugins issue screenshot

Lucky me, for some reason community developers don't pay plugin repositories much attention which led the community managers to open an issue to attract some attention.

That's how I got my starting point, a community plugin called mattermost-plugin-autolink which automatically rewrites text matching a regular expression into a markdown link. The repository had some issues that where tagged with help wanted, which is exactly what I've been looking for.

The help wanted issue I found screenshot

STEP 4: I forked and got my hands dirty

The issue that I picked was a simple migration task, but as dumb as it looks at first I didn't quite understand what exactly I needed to do with the code. But still I forked the code, followed the community guide on how to set up the development environment, built the code and ran the tests. It felt great and motivated me to start working on the code changes.

I was a bit hesitated at first, I placed a comment on the issue, tried to reach out to the community but unfortunately it was almost 2:00 AM. Yet still, I was again determined to finish this and submit a pull request before I go to bed. I was stuck with how to test my code, I looked into the test suite in the repository, found some clues on the possibility of testing my changes, and I kept going.

STEP 5: I didn't hesitate and I submitted my pull request

It was around 2:30 AM when I committed my changes, pushed them to my fork and created a pull request and waited for the CI/CD to pass the checks and it did. I was done, the next step would be feedback from the community managers, iterations and eventually a merge, but the hard part is over.

passing all CI/CD checks screenshot

What I think matters

  1. It's easy to start contributing to any open source project and help build the future of software, you just need to start small.
  2. Don't spend so much time on picking the language and the project, just start with anything, you will later on have answers to all speculations you're questioning.
  3. Find a beginner friendly project and get your hands dirty, don't get overwhelmed with the code base, you don't need to understand everything to be able to help.
  4. Submit!, Don't be scared you might be judged there is always room for improvements. The world will embrace your contribution.

Achieving something is all about the small decisions you make every step along the way, you either decide to continue or to give up. The incremental changes you make to your decisions, no matter how small they are, will bring you closer to what you're aiming for.

Feedback, notes or similar stories? Comment! I would love to hear them.

Top comments (0)