Documentation ¶
Index ¶
- Constants
- type Context
- type DefaultContext
- type DefaultRunner
- type DestDir
- type GitSourceDir
- func (g GitSourceDir) AbsPath() string
- func (g GitSourceDir) Bootstrap() error
- func (g GitSourceDir) Finalize(context Context, rollback bool, err error) error
- func (g GitSourceDir) HooksAbsPath() string
- func (g GitSourceDir) Path() string
- func (g GitSourceDir) TemplateAbsPath() string
- func (g GitSourceDir) Validate() error
- type GopierOptions
- type LocalDestDir
- type LocalSourceDir
- func (l LocalSourceDir) AbsPath() string
- func (l LocalSourceDir) Bootstrap() error
- func (l LocalSourceDir) Finalize(context Context, rollback bool, err error) error
- func (l LocalSourceDir) HooksAbsPath() string
- func (l LocalSourceDir) Path() string
- func (l LocalSourceDir) TemplateAbsPath() string
- func (l LocalSourceDir) Validate() error
- type RenderItem
- type Runner
- type SourceDir
- type TemplateContext
- type ValuesMap
Constants ¶
View Source
const ConfigTemplateCache = "template_cache_dir"
View Source
const ConfigTemplateExt = "template_ext"
View Source
const GitPrefix = "git+"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Context ¶
type Context interface { Src() SourceDir Dest() DestDir Options() *GopierOptions TemplateContext() *TemplateContext }
func CreateDefaultContext ¶
type DefaultContext ¶
type DefaultContext struct {
// contains filtered or unexported fields
}
func (*DefaultContext) Dest ¶
func (d *DefaultContext) Dest() DestDir
func (*DefaultContext) Options ¶
func (d *DefaultContext) Options() *GopierOptions
func (*DefaultContext) Src ¶
func (d *DefaultContext) Src() SourceDir
func (*DefaultContext) TemplateContext ¶
func (d *DefaultContext) TemplateContext() *TemplateContext
type DefaultRunner ¶
type DefaultRunner struct{}
func CreateDefaultRunner ¶
func CreateDefaultRunner() DefaultRunner
func (*DefaultRunner) Run ¶
func (p *DefaultRunner) Run(context Context) error
type GitSourceDir ¶
type GitSourceDir struct {
// contains filtered or unexported fields
}
func (GitSourceDir) AbsPath ¶
func (g GitSourceDir) AbsPath() string
func (GitSourceDir) Bootstrap ¶
func (g GitSourceDir) Bootstrap() error
func (GitSourceDir) Finalize ¶
func (g GitSourceDir) Finalize(context Context, rollback bool, err error) error
func (GitSourceDir) HooksAbsPath ¶
func (g GitSourceDir) HooksAbsPath() string
func (GitSourceDir) Path ¶
func (g GitSourceDir) Path() string
func (GitSourceDir) TemplateAbsPath ¶
func (g GitSourceDir) TemplateAbsPath() string
func (GitSourceDir) Validate ¶
func (g GitSourceDir) Validate() error
Validates wheather the path exists and is a directory
type GopierOptions ¶
type LocalDestDir ¶
type LocalDestDir struct {
// contains filtered or unexported fields
}
func (LocalDestDir) AbsPath ¶
func (l LocalDestDir) AbsPath() string
func (LocalDestDir) Path ¶
func (l LocalDestDir) Path() string
func (LocalDestDir) Validate ¶
func (l LocalDestDir) Validate() error
type LocalSourceDir ¶
type LocalSourceDir struct {
// contains filtered or unexported fields
}
func (LocalSourceDir) AbsPath ¶
func (l LocalSourceDir) AbsPath() string
func (LocalSourceDir) Bootstrap ¶
func (l LocalSourceDir) Bootstrap() error
func (LocalSourceDir) Finalize ¶
func (l LocalSourceDir) Finalize(context Context, rollback bool, err error) error
func (LocalSourceDir) HooksAbsPath ¶
func (l LocalSourceDir) HooksAbsPath() string
func (LocalSourceDir) Path ¶
func (l LocalSourceDir) Path() string
func (LocalSourceDir) TemplateAbsPath ¶
func (l LocalSourceDir) TemplateAbsPath() string
func (LocalSourceDir) Validate ¶
func (l LocalSourceDir) Validate() error
Validates wheather the path exists and is a directory
type RenderItem ¶
type SourceDir ¶
type SourceDir interface { Path() string AbsPath() string Validate() error Bootstrap() error Finalize(context Context, rollback bool, err error) error TemplateAbsPath() string HooksAbsPath() string }
func CreateSourceDir ¶
type TemplateContext ¶
type TemplateContext struct {
Values map[interface{}]interface{}
}
func CreateTemplateContext ¶
func CreateTemplateContext(defaultValuesPath string, valuesPath string) (*TemplateContext, error)
Click to show internal directories.
Click to hide internal directories.