Hi everyone, I recently made my third PR of Hacktoberfest, however unlike my previous blog post, Second PR of Hacktober, where I mentioned the third issue that I made and which I was hoping to work on to have my third PR completed was unfortunately not approved by the repo owner.
So I had to go back to searching GitHub. I looked through some previous students' contributions to last year's Hacktoberfest and came across this repo called Quotes Generator. I noticed that the repo has a feature that allows you to make a post of a generated quote to X (previously Twitter). However, I noticed that the code has not been updated to match the name change of Twitter to X. So I made an issue, and waited for it to be approved by the repo owner. I'll talk about the work I did after the approval below.
Working on The Issue
After I created the issue and had it approved I got to work. In the issue, I mentioned that I wanted to update all instance in the back and front-end of where Twitter was mentioned to now say X and change the term "Tweet This" to "Post This". I split these two tasks up, as I first started by changing any variables names that said Twitter to say X instead, and changed the "Tweet This" to "Post This". Next I had to change the old Twitter logo to the X logo. To get the X logo, I went to Font Awesome and searched for the logo for X. This is where I experienced some problems. Font awesome generates a HTML <i>
tag for you to use the icon. However, this tag was not working for me. To solve this, I had to download two different coloured versions of the icon as SVGs, one version for the website's dark mode and one for light mode. Once I downloaded these images, I then added them to the icons folder and had the dark mode SVG as the default icon to load, since the website loads dark mode first. I then had to update the function that handles switching between dark and light mode, to change the source of the SVG file for the X logo to show the light mode icon and if the user switches the theme back to show the dark mode icon.
Once I finished this, I tested out my work to make sure everything from the icons to the redirect to post the quote on X was working. Testing it was a new experience for me, as the website was built with Docker, which is something I've never used before. So when I first started testing the changes, the icons weren't loading. A quick search made me realize that I had to add the icons folder to the Dockerfile. This was pretty simple, but it made me learn something new about web development. After I added the folder, I tested it out once again and saw that the icons were loading this time. It meant that I could make a commit and create a PR for my contribution.
Creating the PR
Unlike in my last blog post there was no template for when I created this PR. So, when I was creating the description of the PR I made sure to be very descriptive on what changes were done and where they were made. After that, I made the request and waited for the repo owner's response. Thankfully, the repo owner was satisfied with my work and accepted my contribution without asking me to make any modifications.
Overall
This contribution got me one step closer to completing Hacktoberfest. However, you may have noticed that I have not met the goal I set for myself in the past, which was making a contribution to a much larger repo. This was mainly due to me facing the same problem of being overwhelmed by the possible complexity of fixing some of the issues present in those repos. I'm a huge overthinker, and it's something that I need to improve on. Since I sometimes find myself over complicating solutions in my work by thinking that a fix isn't as simple as it sounds in my head. Putting that aside, I did happen to learn something new. I got to have a little experience with Docker, which is a nice take away for me.
At the time of writing this, I have already made my fourth and final issue for which I'm currently awaiting for the repo owner to approve. The issue is made on the Calculator for Everything repo, which is where I made my second PR. In this issue, I've asked to make a Momentum calculator, which should be pretty easy to implement based on my previous work with the Density calculator I made. That concludes this blog post. Thank you all for reading and following my journey through Hacktoberfest so far. I look forward to updating you all in my next post when I make my final PR. Thank you!
Top comments (0)