Documentation ¶
Overview ¶
Package bazel implements the loading of Bazel files.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Build ¶
type Build struct { // WorkspaceName contains the name of the workspace (if any). WorkspaceName core.WorkspaceName // BuildTargets contains the output build targets. BuildTargets core.BuildTargets // contains filtered or unexported fields }
func NewBuild ¶
func NewBuild(sourceFileReader SourceFileReader) *Build
func (*Build) ExecBuildFile ¶
ExecBuildFile executes the BUILD[.bazel] file specified by buildFileLabel. It should be called at most once for each BUILD[.bazel] file.
func (*Build) ExecWorkspaceFile ¶
ExecWorkspaceFile executes the WORKSPACE file (which always has label //:WORKSPACE). It should be called exactly once, before ExecBuildFile is called.
type ContextImpl ¶
type ContextImpl struct {
// contains filtered or unexported fields
}
func GetContextImpl ¶
func GetContextImpl(thread *starlark.Thread) *ContextImpl
TODO(vtl): Maybe get rid of this. We only need this when we need to access the Build, which is when we need it to do a load, but maybe that should be a part of Context.
func (*ContextImpl) BuildTargets ¶
func (self *ContextImpl) BuildTargets() core.BuildTargets
func (*ContextImpl) FileType ¶
func (self *ContextImpl) FileType() core.FileType
func (*ContextImpl) Label ¶
func (self *ContextImpl) Label() core.Label
func (*ContextImpl) SetWorkspaceName ¶
func (self *ContextImpl) SetWorkspaceName(workspaceName core.WorkspaceName) error
func (*ContextImpl) WorkspaceName ¶
func (self *ContextImpl) WorkspaceName() core.WorkspaceName
type SourceFileReader ¶
func GetSourceFileReader ¶
func GetSourceFileReader(workspaceDir string, outputBase string) SourceFileReader
Directories ¶
Path | Synopsis |
---|---|
Package builtins provides the initial globals (builtins) for executing a Bazel file.
|
Package builtins provides the initial globals (builtins) for executing a Bazel file. |
args
Package args contains various helpers for extracting/processing starlark arguments.
|
Package args contains various helpers for extracting/processing starlark arguments. |
functions
Package functions contains implementations of various Bazel (non-rule) functions.
|
Package functions contains implementations of various Bazel (non-rule) functions. |
rules
Package rules contains implementations of Bazel build rules (only callable from BUILD[.bazel] files).
|
Package rules contains implementations of Bazel build rules (only callable from BUILD[.bazel] files). |
workspace_rules
Package workspace_rules contains implementations of Bazel workspace rules (only callable from WORKSPACE files).
|
Package workspace_rules contains implementations of Bazel workspace rules (only callable from WORKSPACE files). |
Package core contains core Bazel concepts.
|
Package core contains core Bazel concepts. |
Package utils contains various utility functions for working with Bazel (build files).
|
Package utils contains various utility functions for working with Bazel (build files). |
Click to show internal directories.
Click to hide internal directories.