package cmd

import "cuelang.org/go/cmd/cue/cmd"

Index

Variables

var ErrPrintedError = errors.New("terminating because of errors")

ErrPrintedError indicates error messages have been printed to stderr.

Functions

func Main

func Main(ctx context.Context, args []string) (err error)

Main runs the cue tool. It loads the tool flags.

Types

type Command

type Command struct {
	// The currently active command.
	*cobra.Command
	// contains filtered or unexported fields
}

func New

func New(args []string) (cmd *Command, err error)

func (*Command) Run

func (c *Command) Run(ctx context.Context) (err error)

func (*Command) SetInput

func (c *Command) SetInput(r io.Reader)

func (*Command) SetOutput

func (c *Command) SetOutput(w io.Writer)

func (*Command) Stderr

func (c *Command) Stderr() io.Writer

Stderr returns a writer that should be used for error messages.

Source Files

add.go cmd.go common.go custom.go eval.go export.go flags.go fmt.go get.go get_go.go import.go root.go trim.go version.go vet.go

Directories

PathSynopsis
cmd/cue/cmd/interfaces
Version
v0.0.9
Published
Sep 9, 2019
Platform
linux/amd64
Imports
49 packages
Last checked
6 minutes ago

Tools for package owners.