Code Management with Git
Operaide Studio includes a built-in Git integration — no terminal required for everyday version control. The Source Control panel provides all the tools you need to track changes, commit, branch, and sync with your remote repository.
This chapter assumes you are already familiar with Git. The focus is on how Git works within the studio and how to connect your App to your own remote repository.
Connecting Your Remote Repository
By default, an App in Operaide Studio is a local Git repository. To back it up or collaborate via your own remote (GitHub, GitLab, Bitbucket, or any other Git host), you need to add a remote origin.
Open the integrated terminal and run:
git remote add origin https://github.com/your-org/your-repo.git
git push -u origin main
From that point on, you can push and pull directly from the Source Control panel in the sidebar — no terminal needed.
Authentication
For HTTPS remotes, Git will prompt for credentials on the first push. Use a personal access token (PAT) instead of your password — most Git providers require this for CLI/API access.
For SSH remotes, add your public key to your Git host and configure the remote accordingly:
git remote set-url origin git@github.com:your-org/your-repo.git
Daily Workflow
The Source Control panel (the branch icon in the left sidebar) gives you a live view of all changes in your workspace.
| State | Meaning |
|---|---|
| Untracked | New file, not yet known to Git |
| Modified | File changed since last commit |
| Staged | Change marked for the next commit |
| Committed | Change saved to local history |
| Pushed | Local commits synced to remote |
Branching and Merging
The current branch is always shown in the status bar at the bottom of the screen. Click it to switch branches or create a new one.
Typical feature branch workflow:
git checkout -b feature/my-feature
# ... develop and commit ...
git push -u origin feature/my-feature
Then open a pull request on your Git host. Once merged, sync your local main:
git checkout main
git pull
Resolving Conflicts
When a merge or pull produces a conflict, Operaide Studio opens a three-panel diff editor — showing the incoming change, your version, and the merged result. Use the inline buttons to accept either side or combine both, then stage the resolved file and commit.
Using the Terminal for Advanced Operations
The Source Control UI covers the most common operations. For anything beyond — rebasing, cherry-picking, resetting, managing submodules — use the integrated terminal directly:
# Interactive rebase of the last 3 commits
git rebase -i HEAD~3
# Cherry-pick a specific commit
git cherry-pick <commit-hash>
# Undo the last commit, keep changes staged
git reset --soft HEAD~1
Best Practices
- Commit frequently — small, focused commits are easier to review and revert
- Write meaningful commit messages — a good subject line summarizes why, not just what
- Use branches — keep
mainstable; develop features and fixes in separate branches - Never commit secrets — AI provider keys, passwords, and tokens do not belong in Git history
- Push regularly — a remote is your safety net; a local-only repo is one accident away from data loss