Set of scripts for preparing a Drupal core release.
tag.sh
: Tags a core releasesec.sh
: Creates a core security releasemanual_merge.sh
and conclude_merge.sh
: Create a security release that requires a manual merge (e.g., for dependency updates)branch.sh
: Creates a new core branch for a new minor versiontag.sh
See https://www.drupal.org/core/maintainers/create-core-release for complete instructions on creating core releases. Use at your own risk!
Execute this script from your local git repository, either by adding it to your path or by using the full path to the script.
Check out the correct branch and ensure you have the latest changes:
git checkout 8.1.x; git pull; git fetch --tags
Run the script:
/path/to/core_release/tag.sh
You will be prompted to enter the release number, as well as the previous and next release numbers if it is not a normal patch release,
A list of the commits since the last release you entered will be copied to the clipboard if you have pbcopy (Mac), or output directly otherwise. Add it to your release notes.
Make sure the script did the right things:
git show
git log
Push your tags and commits manually using the command the script displays. The
command includes a sleep
to avoid a race condition on packaging, so expect it
to sit doing nothing for a bit.
sec.sh
See https://www.drupal.org/core/maintainers/create-core-security-release for complete instructions on creating security releases. Only create security releases in collaboration with the security team and do not share any information (including whetherthere will be a release) outside the security team. (See the security team disclosure policy for more information.)
Execute this script from your local git clone of Drupal core, either by adding it to your system path or by using the full path to the script.
Check out the correct branch(es) and ensure you have the latest changes:
git checkout 8.1.x; git pull
Run the script, with the tag(s) to create as arguments:
/path/to/core_release/sec.sh 8.6.4 8.5.9
You will be prompted to enter information about the SA and the path(s) to patches for each branch. You can tag D7 and D8 releases at the same time with a single command.
Make sure the script did the right things:
git show
git log
git diff 8.1.6 8.1.7
Only push your tags and commits using the command the script displays, and only after you have approval from the security team.
manual_merge_sec.sh
and conclude_merge.sh
Check out the correct branch(es) and ensure you have the latest changes:
git checkout 9.1.x; git pull
Run the script, with the tag(s) to create as arguments:
/path/to/core_release/sec.sh 9.1.3 9.0.11 8.9.13
The script will prompt you for information about the SA, then apply the patches and create working branches. It will stop before merging the tags and output instructions for merging the tags manually.
Follow the instructions to merge the tags after reviewing how to manually resolve the expected merge conflicts.
Run /path/to/cor_release/conclude_merge.sh
.
Make sure the script did the right things:
git show
git log
git diff 9.1.3 9.1.2
Only push your tags and commits using the command the script displays, and only after you have approval from the security team.
branch.sh