Skip to content

tree discover: find the maintainer trees from MAINTAINERS and Next/Trees - #1

Merged
ryanabx merged 1 commit into
mainfrom
tree-discover
Nov 11, 2026
Merged

ryanabx merged 1 commit into
mainfrom
tree-discover

Conversation

@ryanabx

@ryanabx ryanabx commented Nov 11, 2026

Copy link
Copy Markdown
Owner

A maintainer applied a series without replying, and with no trees configured the tree check could not see it. The trees a patch goes to are already written down: MAINTAINERS sections (F:/X:/N:, matched as get_maintainer.pl does) name them on T: lines, and linux-next's Next/Trees gives the branch where a T: line omits it.

tree discover lists, for each open series, the covering sections and their trees, and marks which are already checked; --add adds the rest. In a kernel checkout it needs no options:

  • MAINTAINERS comes from --maintainers, else the mainline tree, else the repository in the current directory.
  • Next/Trees comes from --next-trees (a file, a URL, or "none"), else the next tree's copy, else linux-next's own on git.kernel.org: one request, made only for the kernel's MAINTAINERS. lore.get_text reads it with the same User-Agent and retries as the archive requests.
  • A tree in neither file has no known branch, and it is never guessed: mt76's tree has a "pending" branch, which means not applied. Its branches are listed (trees.remote_heads; --no-ls-remote skips), and with --add in a terminal it asks which one (Enter skips); otherwise it prints the tree add command to run.
  • Series sent to none of the file's L: lists belong to another project and are set aside; matching on people put a U-Boot series through the kernel's file.

Tests mock the ls-remote and the Next/Trees fetch, so they stay offline.

This change was developed with the help of an LLM coding assistant.

A maintainer applied a series without replying, and with no trees
configured the tree check could not see it. The trees a patch goes to
are already written down: MAINTAINERS sections (F:/X:/N:, matched as
get_maintainer.pl does) name them on T: lines, and linux-next's
Next/Trees gives the branch where a T: line omits it.

`tree discover` lists, for each open series, the covering sections and
their trees, and marks which are already checked; `--add` adds the
rest. In a kernel checkout it needs no options:

- MAINTAINERS comes from --maintainers, else the mainline tree, else the
  repository in the current directory.
- Next/Trees comes from --next-trees (a file, a URL, or "none"), else
  the next tree's copy, else linux-next's own on git.kernel.org: one
  request, made only for the kernel's MAINTAINERS. lore.get_text reads
  it with the same User-Agent and retries as the archive requests.
- A tree in neither file has no known branch, and it is never guessed:
  mt76's tree has a "pending" branch, which means not applied. Its
  branches are listed (trees.remote_heads; --no-ls-remote skips), and
  with --add in a terminal it asks which one (Enter skips); otherwise
  it prints the `tree add` command to run.
- Series sent to none of the file's L: lists belong to another project
  and are set aside; matching on people put a U-Boot series through the
  kernel's file.

Tests mock the ls-remote and the Next/Trees fetch, so they stay offline.

This change was developed with the help of an LLM coding assistant.
@ryanabx
ryanabx merged commit bec2a36 into main Nov 11, 2026
12 checks passed
@ryanabx
ryanabx deleted the tree-discover branch November 11, 2026 16:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant