Shared Agents

sa sync · pull team repo

CLI reference

CLI reference

Live help: run sa or sa help — always prefer that over memorizing flags.

sa                  # help overview (default)
sa help             # same
shared-agents …     # alias
sharedagents …      # alias

Without shell aliases:

"${SHARED_AGENTS_HOME:-$HOME/.shared-agents}/scripts/sa" help

Environment: SHARED_AGENTS_HOME (default ~/.shared-agents) · Version: sa version


Command overview

AreaCommandSummary
Infosa · sa helpAll commands
Infosa versionCLI version + HOME
Setupsa bootstrapFull first-time setup
Setupsa installSetup wizard
Setupsa install --non-interactiveAll detected tools, no prompts
Setupsa checkInstalled vs configured
Setupsa syncPull Core + team; link skills & rules
Setupsa statusPending reviews, skills, adapters
Setupsa doctorDiagnose symlink / rule issues
Setupsa doctor --fixRepair + relink
Setupsa team verifyDeep team repo validation
Setupsa team migrateLegacy learnings/team/learnings/
Setupsa uninstallRemove adapters / full uninstall
Learningssa reviewInteractive pending → approved
Learningssa review listList pending
Learningssa pending push [file]Commit + push pending
Learningssa pending path [slug]Canonical pending path
Learningssa unapprove [id|file]Remove from approved
Teamsa skill new · sa skill list · sa skill rmTeam skills
Teamsa rule new · sa rule list · sa rule rmTeam rules

sa sync

sa sync
# = scripts/sync.sh pull
#   1) git pull  ~/.shared-agents        (Core)
#   2) git pull  ~/.shared-agents/team/  (Team)
#   3) sync-links — skills, rules, AGENTS.md/CLAUDE.md blocks
  • Both repos use fast-forward only
  • Without team remote: Core only (solo fallback)
  • Runs quietly on IDE session hooks where configured
  • Run manually after offline work or when a teammate pushed skills/rules

sa status

sa status              # full list
sa status --brief      # one line
sa status --quiet      # only when action needed (exit 1)
sa status --json       # CI / scripts
CheckMeaningAction
Pending learningsFiles in pending/sa review
Not pushedLocal pending changessa pending push
Team setupConfig / legacy layoutsa team verify
Skill symlinksNew skill not linkedsa sync · sa doctor --fix
Rule symlinksFile blocks symlinksa doctor --fix
AdaptersTool present, not configuredsa install

sa doctor

sa doctor
sa doctor --fix
sa doctor --fix -y
sa doctor --fix --dry-run

Backups: $SHARED_AGENTS_HOME/.doctor-backups/. Does not replace the learnings review workflow.


sa check

sa check
sa check --json
STATUSMeaning
okTool present + Shared Agents configured
missing_toolCLI/config not found
not_configuredTool present, adapter missing → sa install
availableGeneric fallback

Learnings commands

sa pending path 2026-06-02-my-slug
sa pending push 2026-06-02-my-slug.md
sa review list
sa review                    # interactive picker
sa review 2026-06-02-my-slug.md
sa unapprove list
sa unapprove <id>

Review flags: --domain, --dry-run, --no-git, -y

Unapprove: --to-pending, --delete, --dry-run, -y

Details: Learnings


Team skills & rules

sa skill new
sa skill list
sa skill rm [name]

sa rule new
sa rule list
sa rule rm [slug]

Create/remove wizards commit + push by default (Enter = yes; --no-git to skip).

Details: Skills and rules


Install flags

Passed through to install.sh:

FlagMeaning
--home DIRTarget path
--source DIRSource repo (dev checkout)
--shell-rc FILEbashrc for sa
--tools IDSComma-separated adapter IDs
--checkStatus only
--dry-runPreview, no writes

See also