These instructions are meant as an introductory, step-by-step guide for new core committers. More experienced committers may have alternate workflows that accomplish the same goals.
Choose a Launchpad Ticket
Review, Install, Test
Review the Code
Code formatting - whitespace, etc.?
Consistency with other code?
Good variable names, clear comments?
Logically well-constructed?
Descriptive commit messages?
Release notes?
Documentation?
Does it need to be rebased to current main? You may do this yourself or ask the original submitter to do so (add the “needsrebase” tag if so).
Are there multiple commits? Some patches may be intentionally split into multiple logical commits, but other patches may just have minor changes and corrections in multiple commits that can be squashed for clarity. Creating a local branch to handle the squashing can be useful, or you may wish to refer it back to the original submitter (add the "needswork" tag if so).
Install the Code
Test the Code
Your level of testing will vary depending on code complexity and how well you understand what it is doing.
Does it work in the UI?
Are there database changes? If so, is there an upgrade script that matches the database changes?
Are there Perl/PostgreSQL/NPM-level tests to run?
Are there any error messages generated in the server logs?
Does ng lint report any issues?
Begin the Merge
git checkout main
git pull origin main
git remote update
git cherry-pick -s [branch id]
git commit –amend
Add signoffs as needed (review Launchpad ticket)
Amend title if needed (make sure it includes LP number)
Add Release Note line if needed:
Handle Upgrade Script (if relevant)
When a database upgrade script is needed, it should be located in Open-ILS/src/sql/Pg/upgrade
Look at current repo to see the next upgrade number (if backporting, use this same number)
Post in
IRC that you will be using the next number:
Make sure that the upgrade script includes the deps_block line and update it with the new number:
Change the file name from XXXX to new number
Update 002.schema.config.sql line 95 (or so) with new number and the current patch's signoffs:
INSERT INTO config.upgrade_log (version, applied_to) VALUES ('1438', :eg_version); – jdoe, rsmith, awalker
Double-check everything:
Stage the changes:
Create a commit that just includes the Launchpad number and "Stamp upgrade script":
Rebase
Merge
Backport?
Decide whether or not the change should be backported. If so, repeat process for whichever actively supported versions it needs to go into (rel_3_12, etc.).
Good reasons to backport:
Good reasons not to backport:
It is a fix for a bug that has only appeared in the current release.
It is a new feature.
It does not backport cleanly.
It changes workflow or display in a disruptive way.
Update Launchpad
Make sure that Launchpad lists each of the versions that you merged the commit to.
Update the status of each to Fix Committed.
Add a comment indicating that you've merged the change (and it's always nice to thank the contributor and testers!)
Remove yourself from the assignment.