cmd

package
v0.17.1 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2024 License: BSD-3-Clause-Clear Imports: 28 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TDFTYPE_ZTDF = "ztdf"
	TDF3         = "tdf3"
	NANO         = "nano"
	Size_1MB     = 1024 * 1024
)

Variables

View Source
var (
	OtdfctlCfg config.Config

	RootCmd = &man.Docs.GetDoc("<root>").Command
)
View Source
var TDF = "tdf"

Functions

func Execute

func Execute(opts ...ExecuteOptFunc)

func HandleSuccess

func HandleSuccess(command *cobra.Command, id string, t table.Model, policyObject interface{})

HandleSuccess prints a success message according to the configured format (styled table or JSON)

func InitProfile added in v0.10.0

func InitProfile(c *cli.Cli, onlyNew bool) (*profiles.Profile, *profiles.ProfileStore)

InitProfile initializes the profile store and loads the profile specified in the flags if onlyNew is set to true, a new profile will be created and returned returns the profile and the current profile store

func MountRoot

func MountRoot(newRoot *cobra.Command, cmd *cobra.Command) error

func NewHandler

func NewHandler(c *cli.Cli) handlers.Handler

instantiates a new handler with authentication via client credentials TODO make this a preRun hook

Types

type ExecuteConfig

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

type ExecuteOptFunc

type ExecuteOptFunc func(c ExecuteConfig) ExecuteConfig

func WithMountTo

func WithMountTo(cmd *cobra.Command, renameCmd *cobra.Command) ExecuteOptFunc

Jump to

Keyboard shortcuts

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