website/docs/sourcehut.md
It is possible to generate changelogs using SourceHut builds.
image: alpine/edge
packages:
- git-cliff
secrets:
- <your-builds.sr.ht-secret>
sources:
- git://[email protected]:~<username>/<repo-name>
environment:
dir: <repo-name>
source: <your-source>
tasks:
- git-cliff: |
cd $dir
git cliff -o CHANGELOG.md
ssh-keyscan -t rsa git.sr.ht >> ~/.ssh/known_hosts
git remote set-url origin $source
git checkout main
git add CHANGELOG.md
git commit -m "chore(release): Update CHANGELOG"
git push -o skip-ci
ssh-keygen -t ed25519 -C "builds.sr.ht" -f ~/.ssh/builds-srht.build.yml:
<your-builds.sr.ht-secret><username><repo-name><your-source>