scripts

package
v0.9.1 Latest Latest
Warning

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

Go to latest
Published: Mar 8, 2024 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CheckNone = 0
	CheckRead = 1 << iota
	CheckWrite
)

Variables

This section is empty.

Functions

func Run

func Run(opts *RunOptions) error

func SetDebug

func SetDebug(debug bool)

Enable the delivery of debug messages to the logger. Only meaningful if a logger is also set.

func SetLogger

func SetLogger(logger log_Logger)

Specify the *log.Logger object where log messages should be sent to.

Types

type Check

type Check uint

type ContentValue

type ContentValue struct {
	RootDir    string
	CheckRead  func(path string) error
	CheckWrite func(path string) error
}

func (*ContentValue) Attr

func (c *ContentValue) Attr(name string) (Value, error)

func (*ContentValue) AttrNames

func (c *ContentValue) AttrNames() []string

func (*ContentValue) Freeze

func (c *ContentValue) Freeze()

func (*ContentValue) Hash

func (c *ContentValue) Hash() (uint32, error)

func (*ContentValue) List

func (c *ContentValue) List(thread *starlark.Thread, fn *starlark.Builtin, args starlark.Tuple, kwargs []starlark.Tuple) (Value, error)

func (*ContentValue) Read

func (c *ContentValue) Read(thread *starlark.Thread, fn *starlark.Builtin, args starlark.Tuple, kwargs []starlark.Tuple) (Value, error)

func (*ContentValue) RealPath

func (c *ContentValue) RealPath(path string, what Check) (string, error)

func (*ContentValue) String

func (c *ContentValue) String() string

func (*ContentValue) Truth

func (c *ContentValue) Truth() starlark.Bool

func (*ContentValue) Type

func (c *ContentValue) Type() string

func (*ContentValue) Write

func (c *ContentValue) Write(thread *starlark.Thread, fn *starlark.Builtin, args starlark.Tuple, kwargs []starlark.Tuple) (Value, error)

type RunOptions

type RunOptions struct {
	Label     string
	Namespace map[string]Value
	Script    string
}

type Value

type Value = starlark.Value

Jump to

Keyboard shortcuts

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