Example #1
0
File: main.go Project: spekode/odin
func greetGreetee(c cli.Command) {
	greeting := c.Parent().Param("greeting")
	greetee := c.Param("greetee")
	str := fmt.Sprintf("%s %s", greeting, greetee)
	str = styleByFlags(str, c)
	c.Println(str, strings.Join(c.Args().Strings(), " "))
}
Example #2
0
File: main.go Project: spekode/odin
// the greet command run by the root command
func greet(c cli.Command) {
	greeting := c.Param("greeting")
	str := fmt.Sprintf("%s", greeting)
	str = styleByFlags(str, c)
	c.Println(str)
}