Documentation
¶
Index ¶
Constants ¶
View Source
const Version = "v1.2.0"
Version of makr
Variables ¶
View Source
var Helpers = map[string]interface{}{ "js_escape": template.JSEscapeString, "html_escape": template.HTMLEscapeString, "json": toJSON, "upcase": strings.ToUpper, "downcase": strings.ToLower, }
Helpers that are automatically injected into templates.
Functions ¶
func GoFmt ¶
GoFmt is command that will use `goimports` if available, or fail back to `gofmt` otherwise.
Types ¶
type Command ¶
type Command struct {
Should ShouldFunc
Command *exec.Cmd
}
Command wraps an exec.Cmd to be run
type File ¶
type File struct {
Path string
Template string
TemplateFuncs template.FuncMap
Permission os.FileMode
Should ShouldFunc
}
File to generate
type Generator ¶
type Generator struct {
Runners []Runnable
Should ShouldFunc
Data Data
}
Generator is the top level construct that holds all of the Runnables
type RemoteFile ¶
RemoteFile represents a remote file (URL) that you want to pull down and write into the project
type ShouldFunc ¶
ShouldFunc decides whether a generator should be run or not
Click to show internal directories.
Click to hide internal directories.