Lessons in GitHub and in Life #Hacktoberfest
Tags: hacktoberfest, opensource, github, career
Published: 2020-09-27 19:01:32

This month I have been working on a project. I thought it would be a simple thing taking only a few hours, but it ended up consuming all my free time and it filled my dreams too.

I wanted to set-up a GitHub Repository that people like me could use to make their #firstPR for #hacktoberfest . 

And when I say "people like me" I mean people who aren't exactly confident of:

* When to make a pull request 
* Why to make a pull request 
* What a good one looks like
* What the difference between the PR and the Commit is 
* When to make a new branch 
* What the branch should be called
* How to contribute to #OpenSource

Well you see, my fears were numerous.

I've been using #GitHub since May 2017 - but I was just forking around :wink: I didn't really know what I was doing. 

I wanted to learn from other people's code. Take stuff that was similar to what I wanted to do and break it down, understand it. Map the patterns of code to my understanding of what it produced. Which is fine... but it left me somewhat confused around stuff that is 2nd nature to most devs.

I looked at a simple repository that encouraged PRs from those looking for a #Good-First-Issue and see if I could build something similar, and whilst building it, learn about those things that I needed to know. 

I actually never anticipated it would work as well as it did.

I started by looking at some of the #awesome-for-beginners repositories linked to Hacktoberfest. They are lists that need to be updated with content, and doing so requires forking, cloning, editing, committing, and making a pull-request. All the things I wanted to understand, but without the difficulty of writing any code - well, maybe some knowledge of Markdown or HTML - but nothing I couldn't figure out.

What I needed was to make a similar list, but include in it all the things a beginner to code needed to know to make that first PR - and then to continue on the coding journey in a non-scary way, that matched their preferred learning style, whilst giving them choices without being overwhelming.

Thus my Hacktoberfest Project was born. I'd love it if you would visit it, :star: :fork_and_knife: (fork it, don't eat it) and :watch: it

{% github msandfor/10-easy-steps %}

I started building the README.MD which is the visible page you see when you go to the GitHub repository. Making that page with the tables and the content was easy enough to do, replicating the styles from the awesome-lists but adding content that I had used to help in my own coding journey.

I noticed some other respositories had cool badges at the top, but I couldn't figure out right away how to add those in. Comparing code on repositories that had the badges with options on the https://img.shields.io website eventually yielded the results I was looking for. 

Then I noticed that people usually triggered PR's as a result of Issues, which so far, I had not even thought about. From the documentation, it seemed that repository owners would ask people who wanted to contribute to raise an issue related to what they wanted to contribute, then do the rest... or they could respond to an existing issue with a contribution, and after committing it, make a PR to Merge the change in. So I created some issues that would have the Labels #good-first-issue #help-wanted #hacktoberfest - Yes that meant I needed to figure out labels as well. Then I realised Issues could be built from Templates - which would better enable #First-Timers-Only to Contribute because I could guide them to provide good Issue/PR information. So I enabled the templates and filled them in. Again - I copied the initial text from other repositories - editing them as I iterated on what I wanted to say.

Next I realised I might get a lot of PR's during Hacktoberfest - so I needed some automation, if I was going to make it work.

That's when I discovered the Probots: 

{% github probot/probot %}

These little bots very quickly became my friends, and fellow contributors. I added Welcome Bot, The Allcontributors bot, and the Auto-Assign Bot. They Welcome new Contributors, send them Gifs, add them to the Contributors acknowledgement in the Readme and assign PR's to me so I can merge them. Now my repository is looking great.

Whilst I was building 10-Easy-Steps I learnt all the things I had wanted to Learn (see above list and add Labels, #Bots and #Automation ). I made 5 issues and 37 PR's, added 3 bots, added 3 templates(one custom), added labels, make branches that aligned to most PRs and many, many commits.

So, I promised you learnings in GitHub and Life... and so far I have talked only of Github (you can get all the How-To info from my 10-easy-steps repository, by claiming an issue and following the instructions). 

* Check out the [README](https://github.com/msandfor/10-Easy-Steps/blob/master/README.md)
* The [Contributing Guidelines](https://github.com/msandfor/10-Easy-Steps/blob/master/contributing.md)
* The [Getting Started Guide](https://github.com/msandfor/10-Easy-Steps/blob/master/docs/getting-started.md)
* The [GitHub Browser Tutorial](https://github.com/msandfor/10-Easy-Steps/blob/master/docs/GitHub-browser-tutorial.md)

But in learning those technical skills, here is also what I learnt to do that applies to Life:

* Ask Questions (If you don't ask How and Why and What and Where and Who... you will just be acting blindly without understanding)
* Take the Initiative #JFDI #DoneIsBetterThanPerfect
* Move out of your comfort zone - if you never try anything new you will never grow
* It's not about the Code (It's about problem solving)
* Copy what others have done before you (Don't reinvent the wheel)
* Break things down into easily understandable pieces
* Then implement in your own way (there is always more than one way to do it, do it in the way that makes sense to you)
* Improve your existing skills (A little bit each day)
* Find mentors to help you (You are not alone)
* Be a mentor and help others (You learn so much more by teaching others - as this project has shown me)
* Build public artifacts that help you gain visibility (check out my 10-easy-steps on Github)
* Better visibility often means better career opportunities too 
* You’ll get better at people skills
* More importantly, You’ll feel empowered and confident
* Nobody knows everything, no-one is perfect, and everyone has a unique set of skills
* Simple is far better than complex
* #OpenSource is the Coders way of asking for #diversity of thought - #Issues are the way you can bring new ideas to the table.