Drafts your next release notes as pull requests are merged into master. Built with Probot.
- Install the Release Drafter GitHub App into the repositories you wish to automatically create releases in.
- Add a
.github/release-drafter.ymlconfiguration file to each repository.
For example, take the following
.github/release-drafter.yml file in a repository:
template: | ## What’s Changed $CHANGES
As pull requests are merged, a draft release is kept up-to-date listing the changes, ready to publish when you’re ready:
You can configure Release Drafter using the following key in your
||Required||The template for the body of the draft release. Use template variables to insert values.|
||Optional||The template to use for each merged pull request. Use change template variables to insert values. Default:
||Optional||The template to use for when there’s no changes. Default:
||Optional||The branches to listen for configuration updates to
Release Drafter also supports Probot Config, if you want to store your configuration files in a central repository. This allows you to share configurations between projects, and create a organization-wide configuration file by creating a repository named
.github and file named
You can use any of the following variables in your
||The markdown list of pull requests that have been merged.|
||A comma separated list of contributors to this release (pull request authors, commit authors, and commit committers).|
||The previous releases’s tag.|
Change Template variables
You can use any of the following variables in
||The number of the pull request, e.g.
||The title of the pull request, e.g.
||The pull request author’s username, e.g.
GitHub Installation Permissions
Release Drafter needs to update your releases for you, and so it requires write access to the repository you want to automatically update. Unfortunately, at this time, GitHub doesn't offer a release-only write scope. Please don't just add it to your entire GitHub account! Only add the repositories you want to draft releases on.
If you have Node v10+ installed locally, you can run the tests, and a local app, using the following commands:
# Install dependencies yarn # Run the tests npm test # Run the app locally npm start
If you don’t have Node installed, you can use Docker Compose:
# Run the tests docker-compose run --rm app npm test
Third-party contributions are welcome! 🙏🏼 See CONTRIBUTING.md for step-by-step instructions.
If you need help or have a question, let me know via a GitHub issue.
If you want to deploy your own copy of Release Drafter, follow the Probot Deployment Guide.
Run the following command:
git checkout master && git pull && npm test && npm version [major | minor | patch]
The command does the following:
- Ensures you’re on master and don’t have local, un-commited changes
- Bumps the version number in package.json based on major, minor or patch
- Runs the
postversionnpm script in package.json, which:
- Pushes the tag to GitHub
- Publishes the npm release
- Deploys to Now
- Opens the GitHub releases page so you can publish the release notes