In the time I was working at Albert Heijn in the GitHub team, I created many GitHub Actions. One I built in my spare time was the martinbeentjes/npm-get-version-action which reads the package.json file to retrieve the version of a package. We needed this for our migration. In last years I barely touched the repository, sometimes I did a small change. This week, I changed two things which made a lot of pipelines break.

What happened?

I merged a Pull Request that used jq to get the version field instead of using a combination of grep and awk. I did not test it properly, it broke. The base Docker image user does not have jq installed. So, that was the first issue.

Secondly, the default branch was changed from master to main and I immediately removed the master branch. In the the example states to use the git tag master for the version. So, what happens when you remove master? Yes, pipelines break!

What did I learn?

This was a great lesson to understand the impact of a simple action makes. The repository is mentioned in over 5k repositories. That means that over 5k repositories will need a mandatory coffee break because of this change. I learned to think through how to setup a, using master as a tag in the example is not the best option. It automatically pulls new changes. Instead, when releasing a version I should change the tag in the as well.

I am grateful for the kind messages of the people thanking me for maintaining this Action, that was a nice feeling. Open Source Software is a cool thing to be active in and I hope to have more open source projects in the future.

Where can you find me

Feel free to follow me on Twitter and GitHub