admin/RELEASE.md
Documentation guide based on the releases of
4.0.5and4.1.0on January 31, 2021.Updated for
4.5.0on April 7, 2024. Updated for4.6.0on January 19, 2025.-MGatner, kenjis
4.x.x: The new release version. (e.g., 4.5.3)4.y: The next minor version. (e.g., 4.6)4.z: The next next minor version. (e.g., 4.7)[!NOTE] Copy this file, and replace the versions above with the actual versions.
develop branch into next minor version branch 4.yBefore starting release process, if there are commits in develop branch that
are not merged into 4.y branch, merge them. This is because if conflicts occur,
merging will take time.
git fetch upstream
git switch 4.y
git merge upstream/4.y
git merge upstream/develop
git push upstream HEAD
developIf you release a new minor version.
4.y into develop:
4.y.0 Merge code4.5) in Setting > Branches >
"Branch protection rules" to the next minor version (e.g. 4.5 → 4.6).4.y branch (this closes all PRs to the branch).Work off direct clones of the repos so the release branches persist for a time.
rm -rf CodeIgniter4.bk userguide.bk
mv CodeIgniter4 CodeIgniter4.bk
mv userguide userguide.bk
git clone [email protected]:codeigniter4/CodeIgniter4.git
git clone [email protected]:codeigniter4/userguide.git
cd CodeIgniter4
git diff --name-status origin/master admin/
When generating the changelog, each pull request to be included must have one of the following labels:
PRs with breaking changes must have the following additional label:
To auto-generate the changelog, navigate to the Releases page, click the "Draft a new release" button.
v4.x.x (Create new tag: v4.x.x on publish)developClick the "Generate release notes" button.
Check the resulting content. If there are items in the Others section which should be included in the changelog, add a label to the PR and regenerate the changelog.
Copy the resulting contents into CHANGELOG.md and adjust the format to match the existing content.
[!NOTE] Most changes that need noting in the User Guide and docs should have been included with their PR, so this process assumes you will not be generating much new content.
Merge any security advisory PRs in private forks.
Add the current version to CHANGELOG.md with the contents generated above.
Update user_guide_src/source/changelogs/v4.x.x.rst
Update user_guide_src/source/installation/upgrade_4xx.rst
git diff --name-status upstream/master -- . ':!.github/' ':!admin/' ':!changelogs/' ':!contributing/' \
':!system/' ':!tests/' ':!user_guide_src/' ':!utils/' \
':!*.json' ':!*.xml' ':!*.dist' ':!rector.php' ':!deptrac.yml' \
':!phpstan*' ':!psalm*' ':!.php-cs-fixer.*' ':!LICENSE' ':!CHANGELOG.md'
tests/ is not used for distribution repos. See admin/starter/tests/.from 4.3.x → from 4.3.8). Run php admin/prepare-release.php 4.x.x and push to origin.
release-4.x.xconst CI_VERSION = '4.x.x';version = '4.x' (if releasing
the minor version) and release = '4.x.x'.Release Date: January 31, 2021<title>CodeIgniter v4.x API</title>
and <version number="4.x.x">define('LATEST_RELEASE', '^4.x')define('NEXT_MINOR', '4.y-dev').define('NEXT_MINOR', '5.0-dev').Prep for 4.x.x release Create a new PR from release-4.x.x to develop:
Prep for 4.x.x releaseUpdates changelog and version references for 4.x.x.
Previous version: #xxxx
Release Code: TODO
New Changelog: TODO
(plus checklist)
Let all tests run, then review and merge the PR.
Create a new PR from develop to master:
4.x.x Ready codeMerge the PR and wait for all tests.
Create a new Release:
v4.x.x (Create new tag: v4.x.x on publish)masterCodeIgniter 4.x.xCodeIgniter 4.x.x release.
See the changelog: https://github.com/codeigniter4/CodeIgniter4/blob/develop/CHANGELOG.md
## New Contributors
*
**Full Changelog**: https://github.com/codeigniter4/CodeIgniter4/compare/v4.x.w...v4.x.x
Watch for the "Deploy Distributable Repos" action to make sure framework, appstarter, and userguide get updated
Run the following commands to install and test appstarter and verify the new
version:
rm -rf release-test
composer create-project codeigniter4/appstarter release-test
cd release-test
composer test && composer info codeigniter4/framework
Verify that the user guide actions succeeded:
Fast-forward develop branch to catch the merge commit from master
git fetch upstream
git checkout develop
git merge upstream/develop
git merge upstream/master
git push upstream HEAD
Update the next minor version branch 4.y:
git fetch upstream
git switch 4.y
git merge upstream/4.y
git merge upstream/develop
git push upstream HEAD
[Minor version only] Create the new next minor version branch 4.z:
git fetch upstream
git switch develop
git switch -c 4.z
git push upstream HEAD
Request CVEs and publish any security advisories that were resolved from private forks (note: publishing is restricted to administrators).
Announce the release on the forums and Slack channel (note: this forum is restricted to administrators).
Run php admin/create-new-changelog.php <current_version> <new_version>
Create a PR for new changelog and upgrade for the next version
You may need to install Sphinx and its dependencies prior to building the User Guide.
This worked seamlessly on Ubuntu 20.04:
sudo apt install python3-sphinx
sudo pip3 install sphinxcontrib-phpdomain
sudo pip3 install sphinx_rtd_theme
rm -rf build/make htmlmake epubrelease-4.x.xrelease-4.x.x to develop:
The User Guide website should update itself via the deploy GitHub Action. Should this fail the server must be updated manually. See repo and hosting details in the deploy script at the User Guide repo.