genny/build/options.go
func (opts *Options) Validate() error {
	pwd, _ := os.Getwd()
	if opts.App.IsZero() {
		opts.App = meta.New(pwd)
	}
	if len(opts.Environment) == 0 {
		opts.Environment = "development"
	}
	if opts.BuildTime.IsZero() {
		opts.BuildTime = time.Now()
	}
	if len(opts.BuildVersion) == 0 {
		opts.BuildVersion = opts.BuildTime.Format(time.RFC3339)
	}
	if opts.rollback == nil {
		opts.rollback = &sync.Map{}
	}
	if len(opts.GoCommand) == 0 {
		opts.GoCommand = "build"
	}
	return nil
}
func (opts *Options) Validate() error {
	pwd, _ := os.Getwd()
	if opts.App.IsZero() {
		opts.App = meta.New(pwd)
	}
	if len(opts.Environment) == 0 {
		opts.Environment = "development"
	}
	if opts.BuildTime.IsZero() {
		opts.BuildTime = time.Now()
	}
	if len(opts.BuildVersion) == 0 {
		opts.BuildVersion = opts.BuildTime.Format(time.RFC3339)
	}
	if opts.rollback == nil {
		opts.rollback = &sync.Map{}
	}
	if len(opts.GoCommand) == 0 {
		opts.GoCommand = "build"
	}
	return nil
}
// Validate that options are usuable