Documentation ¶
Index ¶
- type Deps
- type ErrInstallingPacks
- type ErrNoOyafile
- type ErrNoOyafiles
- type ErrNoProject
- type ErrNoTask
- type Project
- func (p *Project) Changeset(workDir string) ([]*oyafile.Oyafile, error)
- func (p *Project) Deps() (Deps, error)
- func (p *Project) FindRequiredPack(importPath types.ImportPath) (pack.Pack, bool, error)
- func (p *Project) Install(pack pack.Pack) error
- func (p *Project) InstallPacks() error
- func (p *Project) IsInstalled(pack pack.Pack) (bool, error)
- func (p *Project) List(startDir string) ([]*oyafile.Oyafile, error)
- func (p *Project) ListTargets(workDir string, recurse, useChangeset bool) ([]*oyafile.Oyafile, error)
- func (p *Project) Oyafile(oyafilePath string) (*oyafile.Oyafile, bool, error)
- func (p *Project) Oyafiles() ([]*oyafile.Oyafile, error)
- func (p *Project) Require(pack pack.Pack) error
- func (p *Project) Run(workDir string, taskName task.Name, recurse, useChangeset bool, args []string, ...) error
- Bugs
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ErrInstallingPacks ¶ added in v0.0.9
func (ErrInstallingPacks) Error ¶ added in v0.0.9
func (e ErrInstallingPacks) Error() string
type ErrNoOyafile ¶
type ErrNoOyafile struct {
Path string
}
func (ErrNoOyafile) Error ¶
func (e ErrNoOyafile) Error() string
type ErrNoOyafiles ¶
type ErrNoOyafiles struct {
Path string
}
func (ErrNoOyafiles) Error ¶
func (e ErrNoOyafiles) Error() string
type ErrNoProject ¶
type ErrNoProject struct {
Path string
}
func (ErrNoProject) Error ¶
func (e ErrNoProject) Error() string
type Project ¶
type Project struct { RootDir string // contains filtered or unexported fields }
TODO: Duplicated in oyafile module.
func (*Project) Changeset ¶
Changeset returns the list of Oyafiles for the changed directories, based on the Changeset: directives.
The algorithm:
- Add default Changeset task to root Oyafile if there isn’t one - For each project Oyafile:
- If Changeset task defined:
- Contribute to changeset
- Deduplicate changeset - Exclude changes outside work directory
func (*Project) FindRequiredPack ¶
func (*Project) InstallPacks ¶
InstallPacks installs packs used by the project. It works in two steps: 1. It goes through all Import: directives and updates the Require: section with missing packs in their latest versions. 2. It installs all packs that haven't been installed.
func (*Project) ListTargets ¶ added in v0.0.9
Notes ¶
Bugs ¶
Uncached (but used only by Render).
Clean up this magic string & logic duplication everywhere.
We should probably make it more intuitive by supporting Ignore: directives in nested dirs as well as the root dir.
I don't particularly like it how tihs logic is split. Plus we may be masking some other errors this way