cli

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2026 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Overview

Package cli builds the douban command tree on top of the douban library and the any-cli/kit framework. The lookup commands are declared once as kit operations in the douban package, so the CLI, the HTTP API (douban serve), and the MCP server (douban mcp) all derive from one registry. The mirror subsystem is wired here as escape-hatch commands, since a stateful crawl does not fit the emit-records shape of an operation.

Index

Constants

This section is empty.

Variables

View Source
var (
	Version = "dev"
	Commit  = "none"
	Date    = "unknown"
)

Build metadata, set via -ldflags at release time.

Functions

func NewApp added in v0.3.0

func NewApp() *kit.App

NewApp assembles the kit App: the douban domain installs the client factory and the lookup operations, this package adds the mirror and version commands, and kit provides the CLI, API, and MCP surfaces.

Types

type QueueRow added in v0.2.0

type QueueRow struct {
	URL        string `json:"url"`
	EntityType string `json:"entity_type"`
	EntityID   string `json:"entity_id"`
	Source     string `json:"source"`
	Status     string `json:"status"`
	Attempts   int    `json:"attempts"`
	HTTPStatus int    `json:"http_status,omitempty"`
	Error      string `json:"error,omitempty" table:",truncate"`
}

QueueRow is the rendered shape of a frontier row.

Jump to

Keyboard shortcuts

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