neuropoly/changelog

Specify labels via a command-line option (rather than hardcoding)

joshuacwnewton opened this issue · 0 comments

Currently, we hardcode the "PR category" labels for projects in the source code for changelog:

# provides customization to changelog for some repos
options = {
'default': {
'labels': [None],
'generator': default_changelog_generator,
},
'spinalcordtoolbox': {
'labels': ['feature', 'documentation-internal', 'CI', 'bug', 'installation', 'documentation', 'enhancement', 'refactoring', 'git/github'],
'generator': sct_changelog_generator,
},
'ivadomed': {
'labels': ['bug', 'dependencies', 'documentation', 'enhancement'],
'generator': default_changelog_generator,
},
'axondeepseg': {
'labels': ['bug', 'enhancement', 'feature', 'documentation', 'installation', 'testing'],
'generator': default_changelog_generator,
}
}

Doing it this way forces each project to open up a PR if they want to modify how their changelog is generated. (e.g. #28).

Instead, perhaps we could have the usage look like this:

changelog --repo-url ivadomed/ivadomed --labels feature bug installation documentation enhancement [...]

That way, changelog stays project-agnostic, and each project doesn't have to open a PR every time they make a change to their label scheme. 😅