Update new_stuff.go

This commit is contained in:
Adrien Delorme 2020-05-12 12:29:31 +02:00
parent 466358a13e
commit d34cecc668
1 changed files with 8 additions and 2 deletions

View File

@ -9,7 +9,8 @@ type GetBuildsOptions struct {
} }
type BuildGetter interface { type BuildGetter interface {
// GetBuilds return all possible builds for a config. It also starts them. // GetBuilds return all possible builds for a config. It also starts all
// builders.
// TODO(azr): rename to builder starter ? // TODO(azr): rename to builder starter ?
GetBuilds(GetBuildsOptions) ([]Build, hcl.Diagnostics) GetBuilds(GetBuildsOptions) ([]Build, hcl.Diagnostics)
} }
@ -19,15 +20,20 @@ type FixConfigMode int
const ( const (
Stdout FixConfigMode = iota Stdout FixConfigMode = iota
// Inplace fixes your files on the spot.
Inplace Inplace
// Diff shows a full diff.
Diff Diff
// SimpleOutput will simply print what the config should be; it will only
// work when a single file is passed.
SimpleOutput
) )
type FixConfigOptions struct { type FixConfigOptions struct {
DiffOnly bool DiffOnly bool
} }
type OtherInterfaceyMacOtherInterfaceFace interface { type ConfigFixer interface {
// FixConfig will output the config in a fixed manner. // FixConfig will output the config in a fixed manner.
FixConfig(FixConfigOptions) hcl.Diagnostics FixConfig(FixConfigOptions) hcl.Diagnostics
} }