Skip to content

Conversation

@watany-dev
Copy link
Owner

Consolidate multiple git command invocations into a single call:

  • Add GitRepoInfo struct and GetGitRepoInfo() that retrieves root,
    HEAD SHA, and HEAD ref in 2 subprocess calls instead of 3
  • Remove redundant verifyGitRepo() from worktree package, use
    util.FindGitRoot() instead to avoid code duplication
  • Update run.go to use GetGitRepoInfo() for optimized git info retrieval

This reduces startup time by ~100-200ms by eliminating redundant
git subprocess invocations.

Consolidate multiple git command invocations into a single call:
- Add GitRepoInfo struct and GetGitRepoInfo() that retrieves root,
  HEAD SHA, and HEAD ref in 2 subprocess calls instead of 3
- Remove redundant verifyGitRepo() from worktree package, use
  util.FindGitRoot() instead to avoid code duplication
- Update run.go to use GetGitRepoInfo() for optimized git info retrieval

This reduces startup time by ~100-200ms by eliminating redundant
git subprocess invocations.
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.

2 participants