Documentation
¶
Index ¶
- Constants
- func InitContext(dir string) (string, error)
- type Context
- func (c *Context) AddGo(ctx context.Context, goBinary string, alias optional.Val[string], ...) (bool, string, error)
- func (c *Context) AddInclude(ctx context.Context, source string, tags []string) (int, error)
- func (c *Context) CopySource(ctx context.Context, source string, tags []string) (int, error)
- func (c *Context) FindTool(str string) (*Tool, error)
- func (c *Context) GetToolsDir() string
- func (c *Context) LockFilename() string
- func (c *Context) RunTool(ctx context.Context, str string, args ...string) error
- func (c *Context) Save() error
- func (c *Context) SpecFilename() string
- func (c *Context) Sync(ctx context.Context, maxWorkers int, tags []string) error
- func (c *Context) Upgrade(ctx context.Context, tags []string) error
- type GoModule
- type Include
- type Lock
- type RemoteSpec
- type SourceUri
- type SourceUriFile
- type SourceUriGit
- type SourceUriUrl
- type Spec
- type Tool
- type Tools
Constants ¶
View Source
const ( RuntimeGo = "go" SpecFilename = ".toolset.json" LockFilename = ".toolset.lock.json" DefaultToolsDir = "./bin/tools" )
Variables ¶
This section is empty.
Functions ¶
func InitContext ¶
InitContext will initialize context in specified
Types ¶
type Context ¶
func NewContext ¶
func (*Context) AddInclude ¶ added in v0.12.0
func (*Context) CopySource ¶ added in v0.12.0
CopySource will add all tools from source. Source can be a path to file or a http url.
func (*Context) GetToolsDir ¶
func (*Context) LockFilename ¶ added in v0.12.0
func (*Context) SpecFilename ¶
type Include ¶ added in v0.12.0
TODO(zhuravlev): migrate from string to object
func (*Include) UnmarshalJSON ¶ added in v0.14.0
type Lock ¶ added in v0.12.0
type Lock struct {
Tools Tools `json:"tools"`
Remotes []RemoteSpec `json:"remotes"`
}
type RemoteSpec ¶ added in v0.12.0
type SourceUri ¶ added in v0.13.0
type SourceUri interface {
// contains filtered or unexported methods
}
type SourceUriFile ¶ added in v0.13.0
type SourceUriFile struct {
Path string
}
type SourceUriGit ¶ added in v0.13.0
type SourceUriUrl ¶ added in v0.13.0
type SourceUriUrl struct {
URL string
}
type Spec ¶
type Spec struct {
Dir string `json:"dir"`
Tools Tools `json:"tools"`
Includes []Include `json:"includes"`
}
func (*Spec) AddInclude ¶ added in v0.12.0
type Tool ¶
Click to show internal directories.
Click to hide internal directories.