agentleFS
OpenScribblerOpenScribbler/syllago/cli/CLAUDE.md

syllago / cli

CLAUDE.md15 starsChanged 4 months agoApache-2.0View on GitHub

The cli/ directory is the Go codebase for the syllago terminal application. Always run make test after changes to verify nothing broke. Golden file tests will fail if visual output changed without updating baselines. Workflow packages (add, doctor, librarymigrate, lifecycle, loadout, moatinstall, promote, registryops, rollback) compose the core packages and each other. Every other package under internal/ except internal/tui is core and never imports a workflow, so a new package starts out as core. Nothing under internal/ except internal/tui imports…

The file

We split this CLAUDE.md into the rules it gives an agent

1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Naming: Follow standard Go conventions.

    line 54

≈ “Common” is an estimate: at least 1 in 5 of the 26,980 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
CLAUDE.md

CLI Rules

The cli/ directory is the Go codebase for the syllago terminal application.

Build and Test

# From cli/ directory:
make build          # Build binary with version/commit ldflags
make test           # Run all tests
make fmt            # Format with gofmt
make vet            # Run go vet

# TUI-specific:
go test ./internal/tui/ -update-golden   # Regenerate golden files after visual changes

Always run make test after changes to verify nothing broke. Golden file tests will fail if visual output changed without updating baselines.

Package Structure

PackagePurpose
cmd/syllagoEntry point, cobra command wiring
internal/tuiBubbleTea terminal UI (see tui/CLAUDE.md for detailed conventions)
internal/catalogContent discovery, loading, risk indicators
internal/providerProvider detection and configuration
internal/installerInstall/uninstall operations per provider
internal/lifecycleInstall, uninstall, Library-remove and Library-overwrite sequencing shared by every front end: place or unplace, record and pin under the syllago lock, returning an Outcome without printing
internal/converterContent format conversion between providers. Hook conversion uses the canonical interchange format (docs/spec/hooks.md) with provider-neutral names, HookAdapter interface, and read-back verification
internal/auditStructured JSON audit logging for content lifecycle events
internal/configUser configuration management
internal/registryRemote registry client
internal/loadoutLoadout apply/remove/preview logic
internal/promoteLocal-to-shared content promotion
internal/gitutilGit operations (clone, pull, status)
internal/metadataContent metadata parsing
internal/outputCLI output formatting (non-TUI)
internal/parseFile parsing utilities
internal/sandboxSandbox configuration
internal/snapshotSnapshot management
internal/updaterSelf-update logic

Import direction

Workflow packages (add, doctor, librarymigrate, lifecycle, loadout, moatinstall, promote, registryops, rollback) compose the core packages and each other. Every other package under internal/ except internal/tui is core and never imports a workflow, so a new package starts out as core. Nothing under internal/ except internal/tui imports the TUI, a terminal UI library (Charm, bubblezone, termenv), Cobra or pflag, which keeps shared logic usable from the CLI, the TUI and a GUI. depguard enforces both rules in .golangci.yml. A new workflow package needs a ! entry under files and a deny entry in that file's core-imports-no-workflow rule.

Cross a package line by calling the other package's exported functions and types. Add a Go interface only where a second implementation exists or a test needs to substitute one, and define it in the package that consumes it.

Go Conventions

  • Error handling: Return errors, don't panic. Use fmt.Errorf("context: %w", err) for wrapping.
  • Testing: Table-driven tests with t.Run() subtests. Golden files for visual output.
  • Naming: Follow standard Go conventions. Exported types for public API, unexported for internal.
  • Dependencies: Charm stack for TUI (bubbletea, lipgloss, bubbles). Cobra for CLI commands. YAML for config files.

Content Types

Syllago manages these AI tool content types:

  • Rules, Skills, Agents, Commands, Hooks, MCP configs, Loadouts

Content is provider-agnostic at the catalog level. Provider-specific handling (install paths, format conversion) lives in the provider and installer packages.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.