Add notes about how to build a release for a previous version. git-svn-id: https://buddypress.svn.wordpress.org/trunk@14122 cdf35c40-ae34-48e0-9cc9-0c9da1808c22
8.9 KiB
Building a new BuddyPress release
Releasing BuddyPress to the world is a big deal, and takes quite a few manual steps to ensure safe & comfortable updates & upgrades are had by all. Below are the steps release leads go through with each & every release.
Note: These steps vary slightly depending on major/minor/urgency of the deployment to WordPress.org. For questions, or if something is not clear, please ping @JJJ, @boone or @djpaul on Slack. They are mad enough to comprehend how & why all this works the way it does. (We keep planning to automate this, but until then, please enjoy this extremely long and intimidating list of responsibilities.)
Prologue
There are two code repositories, and you’ll be tasked with compiling the BuddyPress codebase from the development repo to the deployment repo. They are separate because BuddyPress is deployed to almost all end-users from the public WordPress.org plugin repository in a way that requires some development assets to be pre-compiled (it’s not a literal 1-to-1 copy) and because BuddyPress is lucky enough to have its own Trac instance on WordPress.org.
Important
We’ll refer to these two repositories like this for the duration of these steps:
[dev]=buddypress.svn.wordpress.org[wporg]=plugins.svn.wordpress.org/buddypress/
Now that you’re familiar, sit back, relax, put on your headgear, and get ready for a trip to the atmosphere…
Preliminary tasks
Note
These tasks are only required for minor/major releases.
- Create a
Releaseschild page on codex called "Version X.Y.Z" so that the permalink looks likehttps://codex.buddypress.org/releases/version-12-4-0/ - Review Noteworthy Contributors and release contributor credits (props). Change as needed.
- If it's a major release, don't forget to find a nice Pizza place to name the release.
- Draft an announcement post on BuddyPress.org like this one.
- If this is a major release, check Trac to see whether there are tickets closed against a minor release that will not happen due to the major release. (For example, 3.3.0 was subsumed into 4.0.0.) If so, reassign those tickets to the major release milestone, and delete the unused milestone.
Version Bumps (in [dev])
Important
For beta-releases (eg: 12.0.0-beta1) and first release candidate, switch to:
/trunk/.
svn switch https://buddypress.svn.wordpress.org/trunk/
Important
For major, minor and RC > 1 releases (eg: 12.1.0 or 12.0.0-RC2), switch to relative branch:
branches/12.0/
svn switch https://buddypress.svn.wordpress.org/branches/12.0/
- Change version in bp-loader.php (plugin header)
- Change version in src/bp-loader.php (plugin header)
- Change $this->version (setup_globals()) in class-buddypress.php
- Change version in package.json
- Use the latest version of npm and: npm install and then npm shrinkwrap
Important
The following steps are only required when releasing a major or minor version.
- Change stable-tag readme.txt
- Change tested-up-to readme.txt
- Add “Upgrade Notice” & “Changelog” entries for this version in readme.txt (major and minor releases)
Commit changes!
svn ci -m 'X.Y.Z version bumps'
Tagging/Branching (in [dev])
Caution
Once created, a tag cannot be removed or edited nor trunk merged to it so please ensure all necessary updates to trunk are committed before creating the tag copy from it.
For Beta (12.0.0-beta1) & first Release Candidate (12.0.0-RC1) releases, create tag from trunk.
svn cp https://buddypress.svn.wordpress.org/trunk https://buddypress.svn.wordpress.org/tags/12.0.0-beta1
Additional task for first Release Candidate (12.0.0-RC1) release: branch from trunk.
svn cp https://buddypress.svn.wordpress.org/trunk/ https://buddypress.svn.wordpress.org/branches/12.0
For Release Candidate > 1, major & minor releases, tag from relevant branch.
svn cp https://buddypress.svn.wordpress.org/branches/12.0 https://buddypress.svn.wordpress.org/tags/12.1.0
Deploying to [wporg]
You’ll probably want to checkout the entire BuddyPress repository from WordPress.org into a local directory. This way you can navigate the entire trunk/branches/tags structure, and more easily make changes as necessary.
mkdir buddypress-wporg-repo
cd buddypress-wporg-repo
svn co https://plugins.svn.wordpress.org/buddypress/ . --ignore-externals
Now you can export the development version of BuddyPress you intend to deploy to users:
mkdir buddypress-to-deploy
cd buddypress-to-deploy
svn co https://buddypress.svn.wordpress.org/tags/12.0.0/ . --force --ignore-externals.
Use the latest version of npm and run: npm install and then composer install && grunt build. (This part can take quite a long time 🧘)
Important
If it's a major or minor release: control everything went fine.
If you are updating the "current" version:
- If lights are green, overwrite the contents of the trunk directory with the contents of
buildin the [wporg] checkout. - If it’s a beta or a release candidate, make sure the Stable tag in both trunk and the newly created tag are the same and are the one of current stable version of BuddyPress.
- Run
svn statto check if you need tosvn addorsvn deletefiles. - Create an svn tag from
trunkusingsvn cp trunk tags/12.0.0. - If it’s not a beta nor a release candidate, make sure the Stable tag in both trunk and the newly created tag are the same and are the one of the new version of BuddyPress. This is needed to make sure GlotPress will successfully update Translation strings.
- Commit & 🤞!
svn ci -m 'Update trunk with X.Y.Z code & create X.Y.Z tag from trunk'
If you are updating a previous version (backporting security fixes for instance):
- Ensure that there is a branch ready to use for the version you are releasing. If you need to create a branch that doesn't exist, search the SVN log for the revision that created the newest release of that version. You can search like this, for instance:
svn log --search 12.5. With the revision number found in the log search, you can create a new branch from the state oftrunkat that release, like this:svn cp -r3259416 trunk branches/12.0. - If lights are green, overwrite the contents of the branch directory for the version you are building (like
branches/12.0) with the contents ofbuildin the [wporg] checkout. - Run
svn statto check if you need tosvn addorsvn deletefiles. - Create an svn tag from the branch you updated above using a command like
svn cp branches/12 tags/12.5.0. - Make sure the Stable tag in
readme.txtintrunkstill matches the "current" version, not the older version you are fixing. - Commit & 🤞!
svn ci -m 'Update branches/12.0 with 12.5.3 code & create 12.5.3 tag from branches/12.0'
Important
If it's a major or minor release: Control everything went fine.
- Go to BuddyPress WP Plugin directory page
- You may need to wait a few minutes, but you should see the main "Download" button of this page is now set to the new version you deployed and the
Version:information into the right sidebar should be set to your new stable tag. - Download the Zip file and check every BuddyPress folders are included.
Tip
Using a tool like DiffMerge can save you some time when checking the content of the downloaded Zip file is the same than your
buddypress-to-deploy/buildfolder.
Announcements
- Publish the announcement post on BuddyPress.org
- Open a new support "super sticky" topic in buddypress.org/support to share the great news with the community and let people eventually ask for support from there.
- Write a post on the BP Team's blog to share the news with our subscribers.
Trac cleanup
- If any tickets remain in milestone, close them or reassign them to a future milestone.
- Close milestone.
- From Trac Admin, ensure that milestone exists for next major and minor releases.
- From Trac Admin, create a Version for the completed release.
Version Bumps (in [dev])
- If it's the first release candidate (eg: 12.0.0-RC1), bump trunk version numbers to alpha in bp-loader.php (14.0.0-alpha).
- If it's a major or minor release, update
[dev]trunk'sreadme.txtstable tag and Upgrade/Changelog informations using the[wporg]trunk's ones.
🏁 Release built! Great job 👏