Syncing and conflicts
What aisync keeps and what it asks about when more than one machine made changes.
The usual flow
aisync push default # upload what you changed here
aisync diff default # see what a pull would change
aisync pull default # get the latest from the repo
When someone pushed first
If the repo has newer commits that didn't touch this profile, your push goes on top of them. Commits to other profiles or to tokens don't block it.
If this profile changed in the repo, you're asked to pull first:
error: profile default changed in the repo since your last pull.
aisync pull default gets it; your local edits stay unless the same file changed on both sides
A pull keeps your edits
A pull looks at each file:
| State | This machine | Repo | What the pull does |
|---|---|---|---|
update |
unchanged | changed | Takes the repo's version |
keep |
changed | unchanged | Leaves your edit; the next push sends it |
conflict |
changed | changed | Stops and asks which to keep |
replace |
first pull, file already there | Backs it up, then replaces it |
Both sides changed the same file
error: these changed both here and in the repo:
conflict file CLAUDE.md (changed here and in the repo)
take the repo's version: aisync pull --force default (yours is backed up first)
keep yours: aisync push --force default (replaces the repo's version)
pull --forcetakes the repo's version. Yours stays in.aisync/backup/.push --forcekeeps yours and replaces that profile's content in the repo.
To merge both, look at your copy in the backup folder, combine them by hand, and push.
Adding new files and servers
A push only reads back what the last pull placed. Add new things yourself:
aisync push default --add skills/deploy
aisync push default --add-server notion
If a new server has a plain-text token the push stops. With --secrets the token moves to the encrypted store and a reference is uploaded instead; this machine's .claude.json is switched to the reference too.
These docs describe aisync 0.1.