@kvasar/openclaw-git
openclaw-git
Full Bitbucket Git workflow for OpenClaw — clone repos, manage branches, diff changes, stage, commit and push without leaving chat.
Tools provided
| Tool | Description |
|---|---|
git_status |
Working-tree status: branch, staged, modified, untracked |
git_clone |
Clone a remote repo (supports shallow clones) |
git_checkout |
Switch branch or create + checkout a new one |
git_branch |
List local/remote branches |
git_diff |
Unified diff (unstaged or staged, optionally scoped to a file) |
git_log |
Recent commit history |
git_add |
Stage files (or everything) |
git_commit |
Create a commit from staged changes |
git_push |
Push branch to remote |
git_pull |
Fetch + merge from remote |
git_stash |
Push/pop/list stash |
git_reset |
Move HEAD (soft / mixed / hard) |
git_worktree_add |
Create a new worktree on a branch (new or existing) |
git_worktree_list |
List all worktrees for a repo |
git_worktree_remove |
Remove a worktree directory |
git_worktree_prune |
Prune stale worktree administrative files |
Tools marked are optional and must be explicitly allowed in config.
Installation
# 1. Install the plugin
openclaw plugins install @kvasar/openclaw-git
# 2. Restart the gateway
openclaw gateway restart
# 3. Update the plugin
openclaw plugins update openclaw-git
Configuration
Bitbucket private repos
Generate an API token in Bitbucket:
- Go to Bitbucket → Personal settings → API tokens
- Click Create API token
- Give it a label (e.g.
openclaw-git) - Set scope: Repositories → Read (add Write if you want to push)
- Copy the generated token
Then add to your OpenClaw config:
{
"plugins": {
"entries": {
"openclaw-git": {
"enabled": true,
"config": {
"bitbucketApiToken": "ATBBxxxxxxxxxxxxxxxx"
}
}
}
}
}How it works: Bitbucket API token auth uses the static username
x-bitbucket-api-token-authwith your token as the password. You can either pass a clean Bitbucket HTTPS URL and let the plugin inject the token from config, or pass a fully credentialed URL directly. The token is redacted from plugin responses.
For SSH clones (git@bitbucket.org:...) no token is needed — your SSH key handles auth normally.
Optional tools allowlist
{
"tools": {
"allow": ["git_push", "git_reset", "git_clone"]
}
}Usage examples
Once installed, just ask the agent naturally:
Clone https://github.com/eclipse-edc/Connector into ~/projects/edc
Show me the status of ~/projects/my-app
Stage all changes in ~/projects/my-app and commit with message "fix: resolve NPE in auth filter"
Show me the diff of src/main/java/App.java before I stage it
Create a new branch feature/vc-policy and push it to origin
Pull the latest changes from main
License
Brought with by Kvasar Technologies
MIT KVASAR Technologies