Expand description
Git utilities for clone, branch management, and repo inspection. Port of src/core/git/git-utils.ts
Structs§
- Branch
Status - Cloned
Repo Info - Commit
Info - Discovered
Skill - GitCommit
Detail - GitCommit
File Change - GitFile
Change - GitGraph
Edge - GitLog
Commit - GitLog
Page - GitLog
Ref - GitRefs
Result - Historical
Related File - Parsed
GitHub Url - Repo
Branch Info - Repo
Changes - Repo
Commit Diff - Repo
File Diff - Repo
Status - Worktree
List Entry
Enums§
Functions§
- branch_
exists - Check if a local branch exists.
- branch_
to_ safe_ dir_ name - Sanitize a branch name for use as a directory name.
- checkout_
branch - compute_
historical_ related_ files - Build historical co-change context for a review diff range.
- copy_
dir_ recursive - Recursively copy a directory, skipping .git and node_modules.
- create_
commit - Create a commit with the given message If files are provided, stages them first Returns the SHA of the created commit
- delete_
branch - dir_
name_ to_ repo - discard_
changes - Discard changes to files in working directory WARNING: This is destructive and cannot be undone
- discover_
skills_ from_ path - Discover skills from a given path (looks for SKILL.md files in well-known subdirectories).
- fetch_
remote - get_
branch_ info - get_
branch_ status - get_
clone_ base_ dir - Base directory for cloned repos.
- get_
commit_ list - Get commit history from current branch
- get_
current_ branch - get_
default_ workspace_ worktree_ root - Default worktree root for a workspace: ~/.routa/workspace/{workspaceId}
- get_
git_ commit_ detail - get_
git_ log_ page - get_
repo_ changes - get_
repo_ commit_ diff - get_
repo_ file_ diff - get_
repo_ status - get_
worktree_ base_ dir - Base directory for worktrees: ~/.routa/worktrees/
- is_
git_ repository - list_
cloned_ repos - List all cloned repos with branch and status info.
- list_
git_ refs - list_
local_ branches - list_
remote_ branches - parse_
git_ status_ porcelain - parse_
github_ url - Parse a GitHub URL or owner/repo shorthand.
- pull_
branch - pull_
commits - Pull commits from remote
- rebase_
branch - Rebase current branch onto target branch
- repo_
to_ dir_ name - reset_
branch - Reset branch to a specific commit or branch mode: “soft” keeps changes staged, “hard” discards all changes
- reset_
local_ changes - stage_
files - Stage files in the Git index
- unstage_
files - Unstage files from the Git index (keep working directory changes)
- worktree_
add - Add a new git worktree. If
create_branchis true, creates a new branch. - worktree_
list - List all worktrees for a repository.
- worktree_
prune - Prune stale worktree references.
- worktree_
remove - Remove a git worktree.