Curiosity CLI

git-sync

Serves a local git repository to the workspace's Git Tracker. The workspace asks for git protocol operations (info/refs, git-upload-pack, ...) over a WebSocket, and the CLI executes them locally with git http-backend, then sends the response back. This lets a workspace index a repo that it cannot reach directly.

The command stays connected until the workspace signals it is done.

Usage

curiosity-cli git-sync \
  --server https://my-workspace.example.com/ \
  --token  $CURIOSITY_TOKEN \
  --path   /home/me/repos/atlas

If --path doesn't yet exist as a directory, the CLI creates it. For an empty directory, run git init (or git clone --bare) inside it before re-invoking — the workspace expects an actual git repo on disk.

Options

Flag Alias Required Default Description
--server -s yes - Workspace URL.
--token -t yes - Library Token.
--path -p yes - Path to a local git repository (created if missing).
--ignore-certificate-errors -i no false Disable TLS validation for both REST and WebSocket. Dev only.
--verbose -v no false Log every request/response, including the full JSON payload.

Requirements

  • The git binary must be on PATH — the CLI launches git http-backend as a child process.
  • The workspace must have a git-tracker configured to talk to a tracker token. Generate one in the workspace under Manage → Tokens → Library with the tracker scopes enabled.

Mutual TLS

If you've set CURIOSITY_CLI_MUTUAL_TLS_CERTIFICATE_PATH (see Common Options), the CLI presents the same client certificate on the WebSocket connection it opens here, not just on REST calls.

Troubleshooting

  • Failed to run command with a generic error — re-run with --verbose to dump the exact request that failed and the git http-backend reply.
  • Repository not found / 404 — make sure the path actually contains a .git/ directory or is a bare repo.
  • Stalls forever — the workspace tracker is expecting a DONE frame from itself when sync is complete. If the workspace process restarts mid-sync, the CLI may sit idle; restart the CLI as well.

See also

© 2026 Curiosity CLI. All rights reserved.