GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(server): a Git project's status and commits leave out the repositories inside it by na0s-fleet-agents[bot] · Pull Request #6 · Na0s/t3code

Conversation

@na0s-fleet-agents

@na0s-fleet-agents na0s-fleet-agents Bot commented Nov 23, 2026

Copy link
Copy Markdown

Problem

When a project's own folder is a Git repository and holds other repositories (which pingdotgg#35925 now counts as part of the project), the root repository's live Git views still include them. git status lists each one as an untracked folder (? api/), the Uncommitted and Changes diffs and the branch change totals count it, and Commit runs git add -A, which stages it as an embedded gitlink ("adding embedded git repository"). Each of those repositories already has its own diff and Git actions, so they show up twice, and committing the root writes broken gitlinks into it.

To reproduce: make a repository shop with a commit, clone or git init two repositories with commits at shop/api and shop/web, edit a file in shop, add shop as a project and open a thread. The commit dialog lists api/ and web/ next to the real change, and committing records both as gitlinks.

Change

The root's Git views now leave out the repositories the project covers inside it, the same way checkpoints already do (nestedScopePaths / excludedPathspecs in CheckpointService.ts and GitVcsDriver.ts).

  • WorkspaceFolders.nestedRepositories returns those repositories for a checkout: the project's folders (discoverFolders plus trackedFolders) when the cwd is the project folder, or the task folder's worktrees when the cwd is a thread's copy of it. It keeps only folders inside the checkout and drops submodules, like nestedScopePaths.
  • GitVcsDriverCore reads them through a VcsNestedRepositories context reference (empty by default, like VcsAutomaticFetchInterval, so tests and other builds keep plain Git behavior) and adds :(top,exclude,literal) pathspecs to status --porcelain=2, the status diff-index --numstat, the branch change totals, the working-tree and branch-range review diff, and the commit-all git add -A.
  • A repository the root's .gitignore lists is dropped from the pathspecs after git check-ignore --no-index, as the checkpoint capture does: git add fails on a pathspec naming an ignored folder.
  • server.ts provides the reference before the first GitVcsDriver build.
  • One sentence in docs/user/multi-repo-projects.md says the project folder's own repository leaves the inner ones out.

Single-file diffs, the Commits source, and repositories a project does not cover (for example ones t3.json ignoreRepositories lists) are unchanged.

Scope

This is a small fix of an obvious bug in pingdotgg#35925's behavior: that change made repositories inside a project folder part of the project and already keeps them out of the root's checkpoints, but the root's live status, diff, and commit still include them. It needs no issue because the defect is a direct inconsistency with what pingdotgg#35925 does for checkpoints, and the fix only applies the same exclusion to the live views. No schema or UI copy changes.

Verification

  • GitVcsDriverCore.test.ts › "leaves the repositories a project covers out of its checkout's Git views" (real Git): a root repository with nested api and web repositories, web also in the root .gitignore, and one root change. It checks status files, branch totals, the Uncommitted review files and patch, and that commit-all commits only the root change and leaves the tree clean. It fails on main's driver (status lists api/). With only the review or only the commit exclusion removed, the review or commit assertion fails.
  • WorkspaceFolders.test.ts: two existing cases extended. One checks that a project folder resolves its discovered repositories (docs, src/web) and that a repository's own folder resolves none. The other checks that a task folder's copy of the project folder resolves its nested worktree (vendor/lib) when Git names the checkout by its resolved path.
  • vp run check:changed origin/main: format, lint, knip, typecheck and tests pass (383 tests in 3 files).
  • vp run scenarios:prove with a scenario (not committed) that seeds a shop repository with nested api and web repositories and one change to notes.md: the scenario fails on base 1368854828 ("expected 2 to be 0" nested rows in the commit dialog) and passes on head.

Commit dialog, before and after:

Before: the commit dialog lists api/ and web/ next to notes.md
After: the commit dialog lists only notes.md

Diff pane, Uncommitted, and the thread details Git panel, before and after:

Before: Uncommitted lists api and web as new files, totals +4
After: Uncommitted lists only notes.md, totals +2

Not checked:

  • The task-folder case end to end in the app. It is covered by the resolver test and by the driver test, but the scenario only covers a local thread.
  • Desktop and mobile clients. The fix is server-side and they read the same status and diff RPCs, but I did not run them.
  • Windows path handling for the resolver (the tests ran on Linux).
  • Performance on a project folder with many top-level folders: each status read of a project folder now runs the same disk scan discoverFolders does for checkpoints. I did not measure it.

Made with Claude Opus 5.5 in Claude Code.

🤖 Generated with Claude Code

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@Na0s @claude
fix(server): a Git project's status and commits leave out the reposit…
2c102be
…ories inside it

When a project's own folder is a Git repository, the repositories the project
covers inside it (pingdotgg#35925) showed up in the root repository's live Git views:
status listed each as an untracked folder, the Uncommitted and Changes diffs and
branch totals counted it, and Commit staged it as an embedded gitlink.

The root's status, numstat, branch totals, working-tree review diff and
commit-all now exclude those repositories, as checkpoints already do. The list
comes from the project's folders (or the task folder's worktrees), and ones the
root's .gitignore lists are dropped from the pathspec so git add does not fail.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@Na0s
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.