At least, it should appear that way.
Anyway, for our third lab, we were required to add 2 new features to our release 0.1 code. This was to get us practicing and learning how to merge branches around and dealing with merge conflicts. The two options I opted for are the following:
Allowed the program to exit with a status code based on the output of the program. If everything went well, it should exit with 0, otherwise, it should exit with a non-zero value. Issue can be found here https://github.com/HyperTHD/URLAutomationMachine/issues/4
Added a -j option that prints out the output in JSON format. Issue can be found here https://github.com/HyperTHD/URLAutomationMachine/issues/5
The features themselves weren't too difficult to create. Just needed to rewrite some functions I wrote previously to account for the potential json format option.
Time to merge. Well, sorta. See, I didn't do any readings on git merge prior so when I just tried to do it, it said that both of my branches were equal with the master branch. This confused me as I was positive that wasn't the case. However, after talking with my professor about this, I realized I made a mistake in not committing to the local branches that I had made. I had uncommitted changes, which meant that as far as git knows, they were on the same level. I went about rectifying this and thankfully, everything was working as intended. I merged the first issue just fine, and had merge conflicts with the second branch as was expected. I fixed the conflicts, then committed to my master branch, followed by my remote repo.
Any person that works with open-source or anything related to github will have to eventually deal with merge conflicts. It's a natural part of the software development life cycle. This lab made me learn about this the hard way. It's a valuable experience that I'll learn to keep with me for the rest of my coding career.
By the way, the resolved commits can be found below:
- The system exit code: https://github.com/HyperTHD/URLAutomationMachine/commit/b10e5e4924716d21df1302f19f11baf91d8e6441
- The json feature: https://github.com/HyperTHD/URLAutomationMachine/commit/6d19820a063e571150935a6ad7f879a4ed1bb64c
Now to go play some Genshin Impact, cause what better way to celebrate finishing this week's open-source material is to play a newly released gacha game. Pray for my wallet, everyone!
Stay tuned!
Top comments (0)