You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Github action that creates a changelog upon PR opening. The changelog will contain all the commit messages grouped by type and change level (major, minor, patch).
Dependencies
To use this action, you need to use it together with action/checkout from github.
We need that to access git changes. See usage example under.
How it works
Whenever you open a PR to master branch, action will compare master branch with your branch and
post a comment to PR with all the changes that are going to be merged to master branch.
There are a few assumptions that you should be aware, when you're using this action.
Assumption
You're release branch is master
You keep clean commit history (ideally squashing your changes so each commit correspond to single change/feature)
You follow one of the following conventions when writing your commit messages - gitmoji or conventional commits. It will work also without that, but your grouping for minor and major changes might be off. For more details, see how we detect changes below.
Besides grouping per change severity, we also sub-group based on change type. That means that first word in commit will be also used to group the changes and order them.
Change level
Major change
Major change is considered every commit that:
includes emoji :boom: or
includes key work BREAKING CHANGE or BREAKING_CHANGE or
first word of the commit contains !
Minor change
Minor change is considered every commit that:
includes emoji :sparkles: or
first word of the commit contains feat
Other changes
Every change that is not MAJOR or MINOR falls under other changes.
Example setup
name: Changelog Generatoron:
# Trigger the workflow on pull request,# but only for the master branchpull_request:
branches:
- mastertypes: [opened, reopened, synchronize]jobs:
changelog:
# Job name is Chanegelogname: Chanegelog Generator# This job runs on Linuxruns-on: ubuntu-lateststeps:
- uses: actions/checkout@v2
- uses: homeday-de/github-action-changelog-generator@v1.0.0with:
token: ${{ secrets.GITHUB_TOKEN }}
Example output
Hey @SinisaG! Here's your changelog.
Major
💥 group by change severity and subtype
Minor
✨ whitelist actions and use dynamic branch
✨ create changelog action