Skip to content

feat(repos): request plans for repos, branches, ssh and tls - #3129

Merged
dan-petty merged 4 commits into
mainfrom
feat/2258-repos-branches-ssh-and-tls-commands
Nov 1, 2026
Merged

dan-petty merged 4 commits into
mainfrom
feat/2258-repos-branches-ssh-and-tls-commands

Conversation

@dan-petty

Copy link
Copy Markdown
Owner

Requested by D · project thread

The 24 branches, repos, ssh and tls commands of #2258 obey the dry-run rule of #412. Each command has a dry-run class, and leaves tests/fixtures/dry_run_gaps.json.

Request plans (10 commands). A dry run makes no external request and prints the numbered requests of the real run, in the order of the run:

  • branches sync, branches update, repos sync and repos update list one git fetch --prune <remote> for each remote and the git pull <remote> <branch> of the tracking branch. The local reads (remotes, current branch, tracking remote) run, because they make no external request. repos sync then lists the code --reuse-window reload.
  • repos clone lists the git clone and the reload. repos clone-org lists the organization listing, the fallback to the own account with its condition, one git clone for each listed repository, and the reload.
  • repos worktrees prune already had a plan (plan_prune). It reads GitHub without --confirm, so its class is request-plan, not "mark only" as the issue table said.
  • ssh register and ssh rotate list the two key POSTs, the listing that a 422 answer starts, and the git config commands that point signing at the key.
  • tls enable-k8s lists, for each namespace, the namespace check, the conditional create, the client-side render and the apply with the rendered secret on standard input.

Each plan comes from the argv builder that the real run calls: git_argv, fetch_commands, pull_command and clone_argv in git/operations.py, org_repos_path and own_repos_path in github/client.py, key_requests in github/ssh.py, git_signing_commands in crypto/ssh_keys.py, and the four kubectl builders in crypto/tls_plans.py. A test for each family runs the real command on a fake that records each call, and compares the calls with the plan.

No external request (14 commands):

  • branches list, repos list, repos worktrees status, ssh audit, ssh list, ssh status, tls inspect and tls verify run normally under devops --dry-run. The commands that had an echo-only --dry-run lose it.
  • branches jira, ssh generate, tls ca, tls cert and tls homelab write local state. Their --dry-run prints one Would ... line and writes nothing. branches clean keeps its own preview, which also applies under devops --dry-run now.
  • tls ca and tls cert leave the MCP exposure table: a no-external-request tool must be read-only, and these two write a private key.

The JSON echo previews (render_dry_run_result) of these commands are removed with no shim. The tests of the five command test files (228 tests) run in 6 s with no process start and no socket.

Closes #2258

Change: openspec/changes/archive/2026-11-01-2258-repos-branches-ssh-and-tls-commands/


Generated by Claude Code

…s in a dry run

Each of the 24 branches, repos, ssh and tls commands of #2258 gets a dry-run
class. The ten that reach git, GitHub or kubectl print a numbered request plan
and make no external request. The plan comes from the same argv builders that
the real run calls (git_plans.py, ssh_plans.py, tls_plans.py). The fourteen
that make no request run under `devops --dry-run`, or preview a local write.
The JSON echo previews are removed. tls ca and tls cert leave the MCP table.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PeiMDqeFH7LNHG89eY7S68
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PeiMDqeFH7LNHG89eY7S68
@dan-petty dan-petty self-assigned this Nov 1, 2026
@dan-petty dan-petty changed the title feat(repos): repos, branches, ssh and tls commands list their requests in a dry run feat(repos): request plans for repos, branches, ssh and tls Nov 1, 2026
The name RENDERED_SECRET_PLACEHOLDER made bandit report B105, and its nosec comment put the src nosec count over its ceiling of 10. The name RENDERED_OUTPUT_PLACEHOLDER gives no B105 finding, so the nosec comment is removed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PeiMDqeFH7LNHG89eY7S68
@dan-petty
dan-petty marked this pull request as ready for review November 1, 2026 23:43
@dan-petty
dan-petty merged commit 174b82c into main Nov 1, 2026
20 checks passed
@dan-petty
dan-petty deleted the feat/2258-repos-branches-ssh-and-tls-commands branch November 1, 2026 23:47
dan-petty pushed a commit that referenced this pull request Nov 2, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.39.0](v0.38.0...v0.39.0)
(2026-11-02)


### Features

* **ci:** uv, test, serve and mcp dry runs list their requests
([#3135](#3135))
([666e183](666e183))
* **k8s:** serve gemini-3.8-flash and two Claude models
([#3117](#3117))
([1fa3a31](1fa3a31)),
closes [#3113](#3113)
* **repos:** request plans for repos, branches, ssh and tls
([#3129](#3129))
([174b82c](174b82c))
* **roadmap:** move unworkable scope to new issues during refine
([#3130](#3130))
([a0b2cb5](a0b2cb5))


### Bug Fixes

* **github:** a refused App JWT names GitHub's reason
([#3116](#3116))
([5ac0bea](5ac0bea))
* **roadmap:** make the alternatives check search before a verdict
([#3127](#3127))
([099c689](099c689))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: dan-petty-release[bot] <346998822+dan-petty-release[bot]@users.noreply.github.com>
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.

feat(repos): repos, branches, ssh and tls commands list their requests in a dry run and make none

2 participants