42 lines
1.4 KiB
Markdown
42 lines
1.4 KiB
Markdown
# CLAUDE.md
|
|
|
|
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
|
|
|
|
`arrman` is a CLI tool to do minimal management of Sonarr and Radarr
|
|
Targeted to be used by AI agents via SKILL.md
|
|
|
|
## Build & Test
|
|
|
|
```bash
|
|
go build -o arrman .
|
|
go test ./...
|
|
go test -run TestName ./pkg/... # single test
|
|
go vet ./...
|
|
```
|
|
|
|
## Architecture
|
|
|
|
- Single self-contained Go binary, no external dependencies
|
|
- Talks HTTPS to Sonarr (TV) and Radarr (films) v3 APIs using API tokens
|
|
- CLI subcommand structure: `arrman [--json] {tv|film|films} {list|add|summary|profiles|rootfolders} [args]`
|
|
- `--json` flag outputs structured JSON (arrays for lists, objects for single items)
|
|
- Sonarr uses TheTVDB IDs for series lookup; Radarr uses IMDB IDs for film lookup
|
|
- Config loaded from `.env` file (SONARR_URL, SONARR_API_KEY, RADARR_URL, RADARR_API_KEY)
|
|
|
|
## Commands
|
|
|
|
- arrman tv list
|
|
- arrman tv list "<title>"
|
|
- arrman tv list "<title>" --include-external
|
|
- arrman films list
|
|
- arrman films list "<title>"
|
|
- arrman films list "<title>" --include-external
|
|
- arrman tv add <title>|<thetvdb series ID> --profile <id> --rootfolder <path>
|
|
- arrman film add <title>|<IMDB ID> --profile <id> --rootfolder <path>
|
|
- arrman tv summary <title>|<thetvdb series ID>
|
|
- arrman film summary <title>|<IMDB ID>
|
|
- arrman tv profiles
|
|
- arrman film profiles
|
|
- arrman tv rootfolders
|
|
- arrman film rootfolders
|