check

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ActivityConf

type ActivityConf struct {
	tableau.ActivityConf
}

func (*ActivityConf) Check

func (x *ActivityConf) Check(hub *tableau.Hub) error

func (*ActivityConf) CheckCompatibility

func (x *ActivityConf) CheckCompatibility(hub, newHub *tableau.Hub) error

type ChapterConf

type ChapterConf struct {
	tableau.ChapterConf
}

func (*ChapterConf) Check

func (x *ChapterConf) Check(hub *tableau.Hub) error

func (*ChapterConf) CheckCompatibility

func (x *ChapterConf) CheckCompatibility(hub, newHub *tableau.Hub) error

type Hub

type Hub struct {
	*tableau.Hub
	// contains filtered or unexported fields
}

func NewHub

func NewHub(options ...tableau.Option) *Hub

func (*Hub) Check

func (h *Hub) Check(dir string, format format.Format, options ...Option) error

func (*Hub) CheckCompatibility

func (h *Hub) CheckCompatibility(dir, newDir string, format format.Format, options ...Option) error

type Option

type Option func(*Options)

Option is the functional option type.

func BreakFailedCount

func BreakFailedCount(count int) Option

BreakFailedCount sets BreakFailedCount option.

func ProtoPackage

func ProtoPackage(protoPackage string) Option

ProtoPackage sets ProtoPackage option.

func SkipLoadErrors

func SkipLoadErrors() Option

SkipLoadErrors sets SkipLoadErrors option as true.

func WithLoadOptions added in v0.2.0

func WithLoadOptions(options ...load.Option) Option

WithLoadOptions sets options for messager loading.

type Options

type Options struct {
	// Break check loop if failed count is equal to or more than BreakFailedCount.
	//
	// Default: 1.
	BreakFailedCount int
	// The proto package name of .proto files.
	//
	// Default: "protoconf".
	ProtoPackage string
	// Whether to ignore errors during loading.
	//
	// Errors may occur during loading old config files when do compatibility
	// check. For example, some new worksheets you recently add are not
	// existed, or proto schema are not compatible, just ignore the loading
	// errors (then these proto message objects are nil after loading), so that
	// compatibility check can continue to run.
	//
	// Default: false.
	SkipLoadErrors bool
	// Options for messager loading.
	//
	// Default: nil.
	LoadOptions []load.Option
}

func ParseOptions

func ParseOptions(setters ...Option) *Options

ParseOptions parses functional options and merge them to default Options.

type ThemeConf

type ThemeConf struct {
	tableau.ThemeConf
}

func (*ThemeConf) Check

func (x *ThemeConf) Check(hub *tableau.Hub) error

func (*ThemeConf) CheckCompatibility

func (x *ThemeConf) CheckCompatibility(hub, newHub *tableau.Hub) error

Jump to

Keyboard shortcuts

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