Skip to content

Instantly share code, notes, and snippets.

@jbottigliero
Created March 25, 2019 23:49
Show Gist options
  • Save jbottigliero/d974554bdf58c814276b3f9c8d9c6a5b to your computer and use it in GitHub Desktop.
Save jbottigliero/d974554bdf58c814276b3f9c8d9c6a5b to your computer and use it in GitHub Desktop.
conventional-changelog-config-spec--v0.1

Conventional Changelog Configuration Spec (v0.1)

Structure

Substitutions


types

An array of type objects representing the explicitly supported commit message types, and whether they should show up in generated CHANGELOGs.

"types": [
    { "type": "feat", "section": "Features"},
    { "type": "fix", "section": "Bug Fixes"},
    { "type": "test", "section": "Tests"},
    { "type": "build", "section": "Build System"},
    { "type": "ci", "hidden": true}
]

type

name type required default description
type string ✔️ N/A A string used to match <type>s used in the Conventional Commits convention.
section string ✖️ N/A The section where the matched commit type will display in the CHANGELOG.
hidden boolean ✖️ N/A Set to true to hide matched commit types in the CHANGELOG.

commitUrlFormat (string)

A URL representing a specific commit at a hash.

{{host}}/{{owner}}/{{repository}}/commit/{{hash}}

See Substitutions for more details on substitutions.

compareUrlFormat (string)

A URL representing the comparison between two git shas.

{{host}}/{{owner}}/{{repository}}/compare/{{previousTag}}...{{currentTag}}

See Substitutions for more details on substitutions.

issueUrlFormat (string)

A URL representing the issueformat (allowing a different URL format to be swapped in for Gitlab, Bitbucket, etc):

{{host}}/{{owner}}/{{repository}}/issues/{{id}}

See Substitutions for more details on substitutions.

Substitutions

All substitutions use Handlebar syntax and templating and will be interpolated as a string.

{{host}}

Default: Normalized host found in package.json.

Available to: commitUrlFormat, compareUrlFormat, issueUrlFormat

{{owner}}

Default: Extracted from normalized package.json repository.url field.

Available to: commitUrlFormat, compareUrlFormat, issueUrlFormat

{{repository}}

Default: Extracted from normalized package.json repository.url field.

Available to: commitUrlFormat, compareUrlFormat, issueUrlFormat

{{hash}}

Default: The commit hash of the tagged release.

Available to: commitUrlFormat

{{previousTag}}

Default: Previous semver tag or the first commit hash if no previous tag is available.

Available to: compareUrlFormat

{{currentTag}}

Default: Current semver tag or or 'v' + version if no current tag is available.

Available to: compareUrlFormat

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment