Skip to content

fix(vscode): Use git repository root instead of workspace folder for …#467

Merged
svarlamov merged 8 commits intogit-ai-project:mainfrom
Christina0215:feature
Feb 9, 2026
Merged

fix(vscode): Use git repository root instead of workspace folder for …#467
svarlamov merged 8 commits intogit-ai-project:mainfrom
Christina0215:feature

Conversation

@Christina0215
Copy link
Copy Markdown
Contributor

@Christina0215 Christina0215 commented Feb 6, 2026

…git-ai commands

Fixed an issue where the VSCode extension failed to detect git notes when VS Code was opened with a workspace root that is not a git repository (e.g., a multi-folder workspace containing multiple git repositories).

Changes:

  • Added getGitRepoRoot() method in blame-service.ts to find the actual git repository root using VS Code's Git extension API
  • Updated executeBlame() to prioritize git repo root over workspace folder
  • Added getGitRepoRoot() method in ai-edit-manager.ts with the same logic
  • Updated checkpoint() method to use git repo root for command execution

Fixes #441

This ensures git-ai blame and checkpoint commands are executed in the correct git repository root, even when VS Code is opened with a workspace that is not a git repository.

Fixes: Git blame information not displayed in workspace mode
Fixes: Checkpoint commands failing with "not a git repository" error


Open with Devin

…git-ai commands

Fixed an issue where the VSCode extension failed to detect git notes when
VS Code was opened with a workspace root that is not a git repository
(e.g., a multi-folder workspace containing multiple git repositories).

Changes:
- Added getGitRepoRoot() method in blame-service.ts to find the actual
  git repository root using VS Code's Git extension API
- Updated executeBlame() to prioritize git repo root over workspace folder
- Added getGitRepoRoot() method in ai-edit-manager.ts with the same logic
- Updated checkpoint() method to use git repo root for command execution

This ensures git-ai blame and checkpoint commands are executed in the
correct git repository root, even when VS Code is opened with a workspace
that is not a git repository.

Fixes: Git blame information not displayed in workspace mode
Fixes: Checkpoint commands failing with "not a git repository" error

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@svarlamov svarlamov self-assigned this Feb 6, 2026
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 potential issue.

View 4 additional findings in Devin Review.

Open in Devin Review

Comment thread agent-support/vscode/src/ai-edit-manager.ts Outdated
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

View 10 additional findings in Devin Review.

Open in Devin Review

Comment thread src/commands/checkpoint_agent/agent_presets.rs
Co-authored-by: devin-ai-integration[bot] <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

View 12 additional findings in Devin Review.

Open in Devin Review

Comment thread agent-support/vscode/src/utils/git-api.ts Outdated
Co-authored-by: devin-ai-integration[bot] <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@svarlamov svarlamov merged commit 89abadf into git-ai-project:main Feb 9, 2026
13 checks passed
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.

GitHub copilot VSCode model unknown and messages empty array

2 participants