Week 7 (July 3-7)

Hello and welcome back to my internship blog journal! I am happy to report that I’m quickly approaching the end of my main project goals. Although review will lead to final modifications, it appears I will have time to work on additional internship tasks.

This Week’s Tasks

This week I completed the initial conversion and clean-up process for all of the Python OBT files. It should be noted that some files were ignored and deleted in the repository due to being a duplicate version.

My primary task for this week was to follow my clean-up process for Bash files for the OBT. I was able to cover over a dozen Bash files using the following steps as defined previously:

  • Look for deprecated Linux commands and replace them with its current counterpart
  • Find unused variables or functions and consider them for removal
  • Remove any clear commented code and its associated pseudocode if applicable

These steps were followed for the above-mentioned files. In addition, I aimed for a higher focus of shortening the length of code. One example involved learning about default parameters in bash. I noticed that there were a lot of long function calls with the same parameters to CheckAndZip in archiveLogs.sh. To save the amount of code, I added default parameters to the function. Instead of passing in the same variables, you can just input “” to get it.

Some other adjustments I added to Bash files included ensuring consistency in snake case by converting camel case variables to it, and removing parts relating to cassandra, not currently used.

Plan For Next Week

There are still plenty of Bash files to cover. My intention is to finish the clean-up for most of the files by the end of next week. It should be mentioned that certain files don’t require any modifications and they remain unchanged.

I look forward to starting other tasks for the project once ready, including making unit tests for certain test system files.

Leave a comment