cli

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2026 License: MIT Imports: 15 Imported by: 0

Documentation

Overview

Package cli — разбор аргументов, команды и вывод консольной утилиты catalogctl. Тонкий транспорт над сервисным слоем: без бизнес-логики (docs/plan/01-architecture.md §2.7).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PrintError

func PrintError(w io.Writer, lang i18n.Language, err error)

PrintError печатает ошибку с префиксом локали и переводом строки: ожидаемые ошибки (*domain.Error) — «Error: »/«Ошибка: », прочие — «Unexpected error: »/«Непредвиденная ошибка: ».

func Run

func Run(args []string, stdout, stderr io.Writer) int

Run выполняет команду catalogctl и возвращает код выхода (docs/plan/04-module-functionality.md §3). Общие опции: --dialect, --db, --dsn, --kind, --system, --dry-run, --lang en|ru (локаль вывода — D9, по умолчанию en); ожидаемые ошибки выводятся с префиксом «Ошибка: », прочие — «Непредвиденная ошибка: », код выхода 1.

Types

This section is empty.

Jump to

Keyboard shortcuts

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