cmdutil

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package cmdutil provides shared helpers for all commands.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AsMap

func AsMap(v any) map[string]any

AsMap safely casts any to map[string]any.

func ExtractList

func ExtractList(data any, listKeys ...string) (raw any, rows []map[string]any, total int, page int)

ExtractList pulls rows and pagination info from a standard API list response.

func Itoa

func Itoa(i int) string

func ServerFromCmd

func ServerFromCmd(cmd *cobra.Command) string

ServerFromCmd extracts the --server flag, falling back to the configured default.

Types

This section is empty.

Jump to

Keyboard shortcuts

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