[Concept,00/17] pickman: Add a manager for cherry-picks

Message ID 20251217022611.389379-1-sjg@u-boot.org
Headers
Series pickman: Add a manager for cherry-picks |

Message

Simon Glass Dec. 17, 2025, 2:25 a.m. UTC
  From: Simon Glass <simon.glass@canonical.com>

This series adds pickman, a tool to help manage cherry-picking commits
between branches. It's designed to automate the tedious process of
cherry-picking large numbers of commits from one branch to another,
such as when maintaining a downstream branch.

Key features:
- Track source branches and cherry-pick progress in a SQLite database
- Find commits to cherry-pick up to the next merge commit
- Use Claude AI agent to automate cherry-picks with conflict resolution
- Create GitLab merge requests for review
- Handle MR review comments automatically
- Poll for continuous automated cherry-picking

The tool integrates with GitLab for MR management and uses the Claude
Agent SDK for automated cherry-picking and conflict resolution.

This tool is *very* experimental (so don't use it yourself!), but should
become usable sometime in the new year.


Simon Glass (17):
  pickman: Add tool to compare branch differences
  pickman: Add argument parsing with compare and test commands
  pickman: Add database for tracking cherry-pick state
  pickman: Add add-source command to track source branches
  pickman: Add list-sources command
  pickman: Add next-set command to show commits to cherry-pick
  pickman: Add pcommit and mergereq tables to database
  pickman: Add a Claude agent
  pickman: Add an apply command to cherry-pick commits
  pickman: Add GitLab API module
  pickman: Add GitLab integration to push and create MRs
  pickman: Add commit-source command
  pickman: Add review command to handle MR comments
  pickman: Add step command to create MR if none pending
  pickman: Add workflow overview to documentation
  pickman: Update database when MRs are merged
  pickman: Process review comments in step command

 .gitignore                  |    1 +
 doc/develop/index.rst       |    1 +
 doc/develop/pickman.rst     |    1 +
 tools/pickman/README.rst    |  236 +++++++
 tools/pickman/__init__.py   |    4 +
 tools/pickman/__main__.py   |   99 +++
 tools/pickman/agent.py      |  221 ++++++
 tools/pickman/control.py    |  732 ++++++++++++++++++++
 tools/pickman/database.py   |  413 +++++++++++
 tools/pickman/ftest.py      | 1309 +++++++++++++++++++++++++++++++++++
 tools/pickman/gitlab_api.py |  345 +++++++++
 tools/pickman/pickman       |    1 +
 12 files changed, 3363 insertions(+)
 create mode 120000 doc/develop/pickman.rst
 create mode 100644 tools/pickman/README.rst
 create mode 100644 tools/pickman/__init__.py
 create mode 100755 tools/pickman/__main__.py
 create mode 100644 tools/pickman/agent.py
 create mode 100644 tools/pickman/control.py
 create mode 100644 tools/pickman/database.py
 create mode 100644 tools/pickman/ftest.py
 create mode 100644 tools/pickman/gitlab_api.py
 create mode 120000 tools/pickman/pickman