mirror of
https://github.com/lukaszraczylo/harness-sync.git
synced 2026-10-12 00:45:22 +00:00
docs: README safety section + CI uses go-version-file
This commit is contained in:
@@ -14,7 +14,7 @@ jobs:
|
|||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- uses: actions/setup-go@v5
|
- uses: actions/setup-go@v5
|
||||||
with:
|
with:
|
||||||
go-version: '1.22'
|
go-version-file: go.mod
|
||||||
cache: true
|
cache: true
|
||||||
- name: vet
|
- name: vet
|
||||||
run: go vet ./...
|
run: go vet ./...
|
||||||
@@ -30,7 +30,7 @@ jobs:
|
|||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- uses: actions/setup-go@v5
|
- uses: actions/setup-go@v5
|
||||||
with:
|
with:
|
||||||
go-version: '1.22'
|
go-version-file: go.mod
|
||||||
cache: true
|
cache: true
|
||||||
- uses: golangci/golangci-lint-action@v6
|
- uses: golangci/golangci-lint-action@v6
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -115,7 +115,7 @@ harness-sync goes out of its way to avoid.
|
|||||||
|
|
||||||
| Harness | Native config | MCP key | Model selector | Instructions | Symlinked |
|
| Harness | Native config | MCP key | Model selector | Instructions | Symlinked |
|
||||||
|---|---|---|---|---|---|
|
|---|---|---|---|---|---|
|
||||||
| **claude-code** | `~/.claude/settings.json` (merged) | `mcpServers` | `env.ANTHROPIC_DEFAULT_MODEL` | `~/.claude/CLAUDE.md` | `skills/`, `agents/` |
|
| **claude-code** | `~/.claude.json` (merged, primary) + `~/.claude/mcp_servers.json` | `mcpServers` (`type: stdio`/`http`) | `env.ANTHROPIC_DEFAULT_MODEL` | `~/.claude/CLAUDE.md` | `skills/`, `agents/` |
|
||||||
| **crush** | `~/.config/crush/crush.json` (merged) | `mcp` (type: stdio\|http\|sse) | `default_model` | auto-read `AGENTS.md` | `skills/` |
|
| **crush** | `~/.config/crush/crush.json` (merged) | `mcp` (type: stdio\|http\|sse) | `default_model` | auto-read `AGENTS.md` | `skills/` |
|
||||||
| **kilo** | `~/.config/kilo/kilo.json` (merged) | `mcp` (type: local\|remote) | `model` + `small_model` | `instructions` array | `agent/` |
|
| **kilo** | `~/.config/kilo/kilo.json` (merged) | `mcp` (type: local\|remote) | `model` + `small_model` | `instructions` array | `agent/` |
|
||||||
| **opencode** | `~/.config/opencode/opencode.jsonc` (merged) | `mcp` (type: local\|remote) | `model` | `AGENTS.md` | — |
|
| **opencode** | `~/.config/opencode/opencode.jsonc` (merged) | `mcp` (type: local\|remote) | `model` | `AGENTS.md` | — |
|
||||||
@@ -142,18 +142,29 @@ harness-sync show [harness...] print files each adapter manages
|
|||||||
harness-sync init import from detected harnesses
|
harness-sync init import from detected harnesses
|
||||||
--from a,b pick adapters, skip prompt
|
--from a,b pick adapters, skip prompt
|
||||||
--no-prompt take all detected
|
--no-prompt take all detected
|
||||||
|
--force allow re-init over existing canonical
|
||||||
harness-sync apply [harness...] render + write
|
harness-sync apply [harness...] render + write
|
||||||
--dry-run show plan, write nothing
|
--dry-run show plan, write nothing
|
||||||
--force overwrite without 3-way merge
|
--force overwrite without 3-way merge
|
||||||
|
--yes skip first-run confirmation prompt
|
||||||
|
--allow-incomplete apply with an unconfigured gateway
|
||||||
harness-sync diff [harness...] apply --dry-run shorthand
|
harness-sync diff [harness...] apply --dry-run shorthand
|
||||||
harness-sync profile list list canonical profiles
|
harness-sync profile list list canonical profiles
|
||||||
harness-sync profile use <name> switch active profile + re-apply
|
harness-sync profile use <name> switch active profile
|
||||||
|
--apply reapply automatically after switching
|
||||||
harness-sync rollback [n] git revert last N apply commits
|
harness-sync rollback [n] git revert last N apply commits
|
||||||
harness-sync adapter list print registered adapters
|
harness-sync adapter list print registered adapters
|
||||||
```
|
```
|
||||||
|
|
||||||
Every command accepts `--root <path>` to point at a non-default canonical tree.
|
Every command accepts `--root <path>` to point at a non-default canonical tree.
|
||||||
|
|
||||||
|
### Production safety
|
||||||
|
|
||||||
|
- **First-run prompt.** The first `apply` against detected harnesses asks for confirmation before moving existing files to backups and replacing them with symlinks. Use `--yes` (or run non-interactively in CI) to skip.
|
||||||
|
- **Profile completeness.** `apply` refuses to proceed when the active profile's `gateway.url` or `gateway.default_model` is empty. The placeholder profile written by `init` is left blank on purpose — edit `profiles/imported.yaml` before applying. `--allow-incomplete` lifts the guard for tests.
|
||||||
|
- **Init guard.** `init` refuses to overwrite an already-initialised canonical tree. Use `--force` to merge new harness imports into existing skills/agents/MCP without clobbering edits.
|
||||||
|
- **Env-var substitution.** `${VAR}` references in profiles and the MCP registry are resolved against the process environment at apply time. A missing variable aborts the run with an explicit error — secrets never silently fall back to empty.
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
## Profiles
|
## Profiles
|
||||||
|
|||||||
Reference in New Issue
Block a user