Attempting to make the composite literals pretty
This commit is contained in:
parent
19158640aa
commit
6efb9862ea
35
cli.go
35
cli.go
@ -6,23 +6,24 @@ func main() {
|
||||
app := App{
|
||||
Name: "math",
|
||||
Description: "a simple command line math utility",
|
||||
Commands: []Command{
|
||||
{
|
||||
Name: "add",
|
||||
Description: "Add 2 and 2",
|
||||
Action: DoAdd},
|
||||
{
|
||||
Name: "subtract",
|
||||
Description: "Subtract 2 and 2",
|
||||
Action: DoSubtract},
|
||||
{
|
||||
Name: "multiply",
|
||||
Description: "Multiply 2 and 2",
|
||||
Action: DoMultiply},
|
||||
{
|
||||
Name: "divide",
|
||||
Description: "Divide 2 and 2",
|
||||
Action: DoDivide}}}
|
||||
Commands: []Command{{
|
||||
Name: "add",
|
||||
Description: "Add 2 and 2",
|
||||
Action: DoAdd,
|
||||
}, {
|
||||
Name: "subtract",
|
||||
Description: "Subtract 2 and 2",
|
||||
Action: DoSubtract,
|
||||
}, {
|
||||
Name: "multiply",
|
||||
Description: "Multiply 2 and 2",
|
||||
Action: DoMultiply,
|
||||
}, {
|
||||
Name: "divide",
|
||||
Description: "Divide 2 and 2",
|
||||
Action: DoDivide,
|
||||
}},
|
||||
}
|
||||
|
||||
app.Run(os.Args[1])
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user