This year, I decided to prepare for Hacktoberfest a bit early. In other words, you could say that the Sample Programs repositories are ready to go for Hacktoberfest 2020.
Table of Contents
What Is the Sample Programs Repo?
For the uninitiated, the Sample Programs repo is a collection of code snippets in as many programming languages as possible. This was a project I kicked off in early 2017, and I’ve largely benefited from the effort of folks during the previous Hacktoberfests to grow the collection to its current size:
- 468 code snippets
- 284 forks
- 260 stars
- 120 programming languages
- 30 projects
- 21 test suites
A lot of folks have been justifiably skeptical of this collection over the years. After all, when something like Rosetta Code already exists, what’s the point in creating a clone?
In the past, my argument revolved around two things. First, it’s okay for similar things to exist in the world because they cater to different individuals. Second, since my project is a lot smaller, it leaves a lot of room for community-driven growth.
That second point is what prompted a lot of change in the repo over the years. For example, many of the code snippets now have documentation in the form of a blog article. This is not the case with Rosetta Code. Likewise, many of the code snippets are tested based on a rigorous set of project standards. I assume Rosetta Code does this, but I’m not sure.
That said, regardless of if you appreciate my argument, I believe a lot of folks have and will continue to get a lot of value out of this collection. In the next section, we’ll talk about how the repo has been prepared for Hacktoberfest 2020.
How Has the Sample Programs Repos Prepared for Hacktoberfest 2020?
If there’s anything you take away from this update, it should be that the Sample Programs repo is now a set of repos. One of the things that had been bothering me is just how unwieldy the repo had grown in the past couple years. At one point, we were storing everything in it from articles to test code to wiki generation code.
Now, I’ve taken the time to pull this repo apart, so it’s a bit easier to manage:
- Sample Programs: just code snippets and tests
- Sample Programs Website: all the website code and all the code snippet documentation
- Sample Programs Wiki Generator: all the code for generating the Sample Programs wiki
To do this, I had to move the docs folder of the Sample Programs repo into its own repo. Then, I moved all the article related issues to the new repo. In addition, I updated the contribution docs and the main README, so everything is a bit more streamlined.
As the maintainer, I feel like the biggest benefit will be project management. Now, when someone wants to add a code snippet, I just have to point them to the projects page of the website.
In addition, another huge benefit of this will be build times for the website. Previously, if we made a change to the website, we’d have to wait for all the code snippets to be validated first. This was a pain, and it completely slowed down the pipeline. Now with the articles separated out, we can make changes to the website much quicker.
Hopefully, these changes will encourage folks like you to begin helping out!
How Can I Help Out?
By the time this article is published, we’ll have about 10 days until Hacktoberfest 2020 officially begins. My request in that time is that you look over the list of currently supported projects or jump straight into the list of open issues (e.g. Sample Programs or Website). From there, you have basically four options:
- Pick a project and begin implementing solutions in various programming languages (e.g. Fibonacci in Perl)
- Pick a project that currently doesn’t have testing and write your own (e.g. Linear Search Testing)
- Pick a language that currently doesn’t have testing and write your own (e.g. MATLAB Testing)
- Come up with a new project and write documentation for it (e.g. Palindrome in Every Language)
Alternatively, you’re always welcome to write documentation for existing articles. This is something that has really not gotten the support it deserves. As a result, I plan to incentivize it a bit by sharing your article on my website if you’d like.
Beyond that, I’m open to anything. One of the best things about having community-driven project like this is I’ve always been able to watch the project grow and change over time. This year I expect this trend to continue!
Best of Luck!
If you haven’t had a chance to take part in Hacktoberfest up until this year, that’s okay! I personally haven’t contributed to a repo other than my own. Perhaps you might try starting your own project as well.
That said, if you do decide to help out with the Sample Programs collection, I’d really appreciate it. Otherwise, no hard feelings!
While you’re waiting for Hacktoberfest 2020 to kick off, why not check out some of my other articles. For instance, I recently started a Python series for folks looking to learn the language. Here are a few to get you started:
Likewise, here are some Python resources from the folks at Amazon (ad):
- Effective Python: 90 Specific Ways to Write Better Python
- Python Tricks: A Buffet of Awesome Python Features
- Python Programming: An Introduction to Computer Science
Once again, thanks for taking some time to stop by! I appreciate it.