post-commit hook to generate a changelog page for your Jekyll site
Last year I decided to make my blog private, it enables me to have private sections accessible only to those who have the url.
Yet, I missed some of the transparency history provided by public repositories and opted for an in-between solution :
- for each commit of type
feat
orfix
a line is added on the Changelog page - some filepaths can be kept secret by not reporting related commits
- although Changelog page additions are automated, commiting it is a task left to human operator
All you need is to add a sentinel to an empty Changelog page like so :
And copy this git post-commit hook in your Jekyll repository :
That’s it, you now have a semi-automated Changelog page.