Repos is now in Public Beta! Reach out to us at info@relace.ai if you have any
questions or need help with the integration.
git clone, git push, and git pull can be used natively with Relace Repos. Git is a convenient way to send/receive the minimal amount of necessary information for low overhead synchronization with your source of truth.
We recommend using git for best performance.
This guide assumes you’ve already created a Relace Repo, and you’re trying to use it within a sandbox or other local file system. We go through two options — using git directly in the command line or within scripts via the Relace SDK.
Command Line Syntax
When using git directly from the command line, Relace Repos can be accessed using the following URL format:YOUR_API_KEYis your Relace API keyYOUR_REPO_IDis the id of the repo you want to interact with
Development Workflow
1
Clone Relace Repo
Start by cloning the repo into your local environment.
By default, the Relace SDK uses shallow clones for lowest latency. If you need
the full git history, you can explicity specify these parameters.
2
Stage, commit, and push all changes
After making changes to the files locally, you can push the changes back to the corresponding repo.Make sure to include a
.gitignore file
in your repo to avoid sending large files and binaries (like node_modules/,
dist/, etc.).3
Pull latest changes before making more changes
Other Git Commands
All standard git commands are supported with Relace Repos, includinggit fetch, git checkout, git branch, git merge, git log, and more. You can use Relace Repos just like any other git remote.
For the complete API reference and additional repository operations, see the Repos API Reference.