cmdutil

package
v0.0.0-...-af821a4 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DockerImage string
)

Functions

func AddGroup

func AddGroup(parent *cobra.Command, title string, cmds ...*cobra.Command)

func CanonicalizePaths

func CanonicalizePaths(paths ...*string) error

func CreateFolder

func CreateFolder(path string) error

CreateFolder Checks if folder exists and if it doesn't it creates it.

func IsFileAudio

func IsFileAudio(filepath string) (bool, error)

func IsFileAudioOrVideo

func IsFileAudioOrVideo(filepath string) (isAudio, isVideo bool, err error)

func IsFileImage

func IsFileImage(filepath string) (bool, error)

func IsFileVideo

func IsFileVideo(filepath string) (bool, error)

func PathsToMounts

func PathsToMounts(paths ...string) (mounts map[string]string)

PathsToMounts adds active directory, prepares dirs for docker volume binding

func ReadFileIntoJSON

func ReadFileIntoJSON(path string, jsonStruct any) error

Types

type Factory

type Factory struct {
	Logger *zap.Logger
	Docker docker.Wrapper

	IgnoreValidations bool
	Daemon            bool
	Debug             bool
}

func NewFactory

func NewFactory(logger *zap.Logger) *Factory

func (*Factory) ListenForCancelSignals

func (f *Factory) ListenForCancelSignals(cancel context.CancelFunc)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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