cmd

package
v1.0.0-rc.38 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2023 License: MIT Imports: 35 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CommandGroupCore      = "core"
	CommandGroupExtension = "extension"
)

Variables

View Source
var (
	Version = "dev"
	Date    = "unknown"
)
View Source
var (
	MaxHeight = LookupIntEnv("SUNBEAM_HEIGHT", 0)
)

Functions

func BearerMiddleware

func BearerMiddleware(token string) func(next http.Handler) http.Handler

func FindExtensions

func FindExtensions() (map[string]tui.Extension, error)

func IsRootCommand

func IsRootCommand(command types.CommandSpec) bool

func LookupBoolEnv

func LookupBoolEnv(key string, fallback bool) bool

func LookupIntEnv

func LookupIntEnv(key string, fallback int) int

func NewCmdCustom

func NewCmdCustom(extensions map[string]tui.Extension, alias string) (*cobra.Command, error)

func NewCmdExtension

func NewCmdExtension() *cobra.Command

func NewCmdExtensionBrowse

func NewCmdExtensionBrowse() *cobra.Command

func NewCmdExtensionInstall

func NewCmdExtensionInstall() *cobra.Command

func NewCmdExtensionList

func NewCmdExtensionList() *cobra.Command

func NewCmdExtensionRemove

func NewCmdExtensionRemove() *cobra.Command

func NewCmdExtensionRename

func NewCmdExtensionRename() *cobra.Command

func NewCmdExtensionUpgrade

func NewCmdExtensionUpgrade() *cobra.Command

func NewCmdFetch

func NewCmdFetch() *cobra.Command

func NewCmdQuery

func NewCmdQuery() *cobra.Command

func NewCmdRun

func NewCmdRun() *cobra.Command

func NewCmdServe

func NewCmdServe() *cobra.Command

func NewCmdValidateCommand

func NewCmdValidateCommand() *cobra.Command

func NewCmdValidateManifest

func NewCmdValidateManifest() *cobra.Command

func NewCmdValidatePage

func NewCmdValidatePage() *cobra.Command

func NewRootCmd added in v0.9.0

func NewRootCmd() (*cobra.Command, error)

func NewValidateCmd added in v0.4.1

func NewValidateCmd() *cobra.Command

Types

type Config

type Config struct {
	Root map[string]types.Command `json:"root"`
}

func LoadConfig

func LoadConfig() (Config, error)

type ExtensionCache

type ExtensionCache map[string]types.Manifest

type History

type History struct {
	// contains filtered or unexported fields
}

func LoadHistory

func LoadHistory(fp string) (History, error)

func (History) Save

func (h History) Save() error

Jump to

Keyboard shortcuts

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