syncmd

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 30, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package sync keeps tool-specific instruction files aligned with AGENTS.md. Claude Code does not read AGENTS.md natively, so the recommended bridge is a one-line `@AGENTS.md` import inside CLAUDE.md (per Anthropic docs) — no fragile symlinks, no duplicated content.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action struct {
	Tool   string `json:"tool"`
	Path   string `json:"path"`
	Status string `json:"status"` // created | updated | up-to-date | would-create | would-update
	Detail string `json:"detail,omitempty"`
	Mode   string `json:"mode"`
}

Action describes what sync did (or would do) for one target.

type Mode

type Mode string

Mode selects how tool files are bridged to AGENTS.md.

const (
	ModeImport  Mode = "import"  // one-line @AGENTS.md import (default)
	ModeCopy    Mode = "copy"    // full copy of content
	ModeSymlink Mode = "symlink" // filesystem symlink
)

type Result

type Result struct {
	Actions    []Action `json:"actions"`
	InSync     bool     `json:"in_sync"`
	ExitErrors []string `json:"exit_errors,omitempty"`
}

Result is the aggregate outcome.

func Run

func Run(root string, mode Mode, tools []string, checkOnly bool, copyBody string) *Result

Run performs (or, with checkOnly, simulates) the sync.

type Target

type Target struct {
	Tool string // claude | gemini
	Path string
}

Target is one bridgeable file.

func Targets

func Targets() []Target

Targets lists the bridges agentsmd manages.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL