Files
hub/.changelogrc.js
Jon Leopard acb0872a84 ci: configure auto-changelog for Gitea and add CHANGELOG
- Add conventional-changelog-cli for automatic changelog generation
- Fix Gitea URL format (use /commit/ not /commits/)
- Generate initial CHANGELOG.md from commit history
- Add npm run changelog script with sed fix for Gitea URLs

This enables automatic changelog generation from conventional commits
while maintaining compatibility with Gitea's URL structure.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-23 02:19:37 -07:00

28 lines
1.2 KiB
JavaScript

// Conventional Changelog configuration for Gitea
const conventionalChangelogConfig = {
preset: {
name: 'conventionalcommits',
types: [
{ type: 'feat', section: 'Features' },
{ type: 'fix', section: 'Bug Fixes' },
{ type: 'perf', section: 'Performance Improvements' },
{ type: 'revert', section: 'Reverts' },
{ type: 'docs', section: 'Documentation', hidden: true },
{ type: 'style', section: 'Styles', hidden: true },
{ type: 'chore', section: 'Miscellaneous Chores', hidden: true },
{ type: 'refactor', section: 'Code Refactoring', hidden: true },
{ type: 'test', section: 'Tests', hidden: true },
{ type: 'build', section: 'Build System', hidden: true },
{ type: 'ci', section: 'Continuous Integration', hidden: true },
],
},
writerOpts: {
// Gitea uses /commit/ (singular) not /commits/ (plural) like GitHub
commitUrlFormat: '{{host}}/{{owner}}/{{repository}}/commit/{{hash}}',
compareUrlFormat: '{{host}}/{{owner}}/{{repository}}/compare/{{previousTag}}...{{currentTag}}',
issueUrlFormat: '{{host}}/{{owner}}/{{repository}}/issues/{{id}}',
},
};
module.exports = conventionalChangelogConfig;