directory

package
v0.32.1 Latest Latest
Warning

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

Go to latest
Published: May 3, 2024 License: Apache-2.0 Imports: 24 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	CheckUnknown checkType = iota
	Check
	CheckRelation
	CheckPermission
	CheckDecision
)

Variables

This section is empty.

Functions

func UnmarshalRequest

func UnmarshalRequest[T any, M Message[T]](src string, msg M) error

Types

type BackupCmd

type BackupCmd struct {
	File   string        `arg:""  default:"backup.tar.gz" help:"absolute file path to make backup to"`
	Format FormatVersion `flag:"" short:"f" enum:"3,2" name:"format" default:"3" help:"format of json data"`
	clients.DirectoryConfig
}

func (*BackupCmd) Run

func (cmd *BackupCmd) Run(c *cc.CommonCtx) error

type DirectoryCmd

type DirectoryCmd struct {
	Import  ImportCmd  `cmd:"" help:"import directory data"`
	Export  ExportCmd  `cmd:"" help:"export directory data"`
	Backup  BackupCmd  `cmd:"" help:"backup directory data"`
	Restore RestoreCmd `cmd:"" help:"restore directory data"`
	Test    TestCmd    `cmd:"" help:"execute directory assertions"`
}

type ExportCmd

type ExportCmd struct {
	Directory string        `short:"d" required:"" help:"directory to write .json data"`
	Format    FormatVersion `flag:"" short:"f" enum:"3,2" name:"format" default:"3" help:"format of json data"`
	clients.DirectoryConfig
}

func (*ExportCmd) Run

func (cmd *ExportCmd) Run(c *cc.CommonCtx) error

type FormatVersion

type FormatVersion int
const (
	V2 FormatVersion = 2
	V3 FormatVersion = 3
)

type ImportCmd

type ImportCmd struct {
	Directory string        `short:"d" required:"" help:"directory containing .json data"`
	Format    FormatVersion `flag:"" short:"f" enum:"3,2" name:"format" default:"3" help:"format of json data"`
	clients.DirectoryConfig
}

func (*ImportCmd) Run

func (cmd *ImportCmd) Run(c *cc.CommonCtx) error

type Message

type Message[T any] interface {
	proto.Message
	*T
}

type RestoreCmd

type RestoreCmd struct {
	File   string        `arg:""  default:"backup.tar.gz" help:"absolute file path to local backup tarball"`
	Format FormatVersion `flag:"" short:"f" enum:"3,2" name:"format" default:"3" help:"format of json data"`
	clients.DirectoryConfig
}

func (*RestoreCmd) Run

func (cmd *RestoreCmd) Run(c *cc.CommonCtx) error

type TestCmd

type TestCmd struct {
	Exec     TestExecCmd     `cmd:"" help:"execute assertions"`
	Template TestTemplateCmd `cmd:"" help:"output assertions template"`
}

type TestExecCmd

type TestExecCmd struct {
	File    string `arg:""  default:"assertions.json" help:"filepath to assertions file"`
	NoColor bool   `flag:"" default:"false" help:"disable colorized output"`
	Summary bool   `flag:"" default:"false" help:"display test summary"`

	clients.DirectoryConfig
	// contains filtered or unexported fields
}

func (*TestExecCmd) Run

func (cmd *TestExecCmd) Run(c *cc.CommonCtx) error

nolint: funlen,gocyclo

type TestTemplateCmd

type TestTemplateCmd struct {
	V2     bool `flag:"" default:"false" help:"use v2 template"`
	Pretty bool `flag:"" default:"false" help:"pretty print JSON"`
}

func (*TestTemplateCmd) Run

func (cmd *TestTemplateCmd) Run(c *cc.CommonCtx) error

Jump to

Keyboard shortcuts

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