Documentation
¶
Index ¶
Constants ¶
View Source
const ( ApplyFileFlag = "apply" ApplyDirectoryFlag = "directory" ApplyNameFlag = "name" ApplyVarFlag = "var" ApplyVarFileFlag = "var-file" )
View Source
const ( InterpolateFileFlag = "interpolate" InterpolateDirectoryFlag = "directory" InterpolateNameFlag = "name" InterpolateVarFlag = "var" InterpolateVarFileFlag = "var-file" )
Variables ¶
View Source
var Apply = &cli.Command{ Name: "apply", Description: "applies the specified template to the target directory", Usage: "Applies the specified template to the target directory", UsageText: "caster apply (-f <TEMPLATE_FILE> | -d <TEMPLATE_DIRECTORY | -n <NAME>) [<TARGET>]", Action: ApplyAction, Flags: []cli.Flag{ &cli.StringFlag{ Name: ApplyFileFlag, Aliases: []string{"f"}, }, &cli.StringFlag{ Name: ApplyDirectoryFlag, Aliases: []string{"d"}, }, &cli.StringFlag{ Name: ApplyNameFlag, Aliases: []string{"n"}, }, &cli.StringSliceFlag{ Name: ApplyVarFlag, }, &cli.StringSliceFlag{ Name: ApplyVarFileFlag, TakesFile: true, }, }, }
View Source
var Interpolate = &cli.Command{ Name: "interpolate", Description: "interpolates the specified template and outputs the result", Usage: "interpolates the specified template and outputs the result", UsageText: "caster interpolate (-f <TEMPLATE_FILE> | -d <TEMPLATE_DIRECTORY | -n <NAME>) [<TARGET>]", Action: InterpolateAction, Flags: []cli.Flag{ &cli.StringFlag{ Name: InterpolateFileFlag, Aliases: []string{"f"}, }, &cli.StringFlag{ Name: InterpolateDirectoryFlag, Aliases: []string{"d"}, }, &cli.StringFlag{ Name: InterpolateNameFlag, Aliases: []string{"n"}, }, &cli.StringSliceFlag{ Name: InterpolateVarFlag, }, &cli.StringSliceFlag{ Name: InterpolateVarFileFlag, TakesFile: true, }, }, }
Functions ¶
func ApplyAction ¶
func InterpolateAction ¶
Types ¶
type ApplyCommand ¶
type ApplyCommand struct {
Options ApplyOptions
Environment env.Environment `inject:""`
Service cast.Service `inject:""`
}
func (*ApplyCommand) Execute ¶
func (cmd *ApplyCommand) Execute() error
type ApplyOptions ¶
type InterpolateCommand ¶
type InterpolateCommand struct {
Options InterpolateOptions
Environment env.Environment `inject:""`
Service interpolate.Service `inject:""`
Console console.Console `inject:""`
}
func (*InterpolateCommand) Execute ¶
func (cmd *InterpolateCommand) Execute() error
Click to show internal directories.
Click to hide internal directories.