Automatically updating spec files
Hi Chetan! I've been using your specs for a while, thank you for maintaining zellij and helix!
Your setup inspired me to look into how specs work, and in doing that I've made my own setup here and wrote a small script to bump version numbers based on the latest Github release. I wanted to bring it to your attention in case you'd find it useful for updating your own specs all at once.
You can find the script/Github repo here. It parses all spec files, checks the latest github release and updates the spec file if needed. It can be integrated into CI/CD: for example, I've hooked it into Github Actions to run every 24 hours and push any changes to my spec files with corresponding tags, which will trigger an automatic COPR rebuild. The Github repo linked earlier has documentation.
It seems to handle most cases in your repo well, here's the output of a dry run on this repo:
WARNING:root:jpm does not have a latest version, skipping
Name Old Version New Version
carp 0.5.5 (no update)
elm 0.19.1 (no update)
gitoxide 0.21.0 0.12.2
helix 23.03 (no update)
janet 1.23.0 1.27.0
juliaup 1.8.12 1.8.16
macchina 6.0.6 6.1.8
onefetch 2.16.0 (no update)
zellij 0.35.2 (no update)
To update the spec files, run again without the dry-run flag.
gitoxide
is incorrect, if you wanted to use this you'd probably need to hardcode it to ignore gitoxide or do something clever to get the right release. gitoxide makes releases for each of their crates, so the latest github release is not the latest gix release. You'll also note that jpm doesn't use releases so the script ignores it.
Everything else is valid! janet, juliaup, and macchina do have those updates, and the script can make new spec files with those versions.
Please feel free to totally ignore this if it wouldn't be useful, but if it would be useful please feel free to copy it and make whatever changes you need! It can be used as simply as manually running it every few days to get all the updates and then you can manually spotcheck for errors, or as fancy as integrating it into an automatic system to do updates for you :)