@@ -5,14 +5,14 @@ import (
55 "github.com/spf13/cobra"
66)
77
8- var sawCommand = & cobra.Command {
8+ // SawCommand is the main top-level command
9+ var SawCommand = & cobra.Command {
910 Use : "saw <command>" ,
1011 Short : "A fast, multipurpose tool for AWS CloudWatch Logs" ,
11- Long : "Saw is a fast, multipurpose tool for cutting through AWS CloudWatch Logs." ,
12- Example : ` saw version
13- saw groups --prefix prod
14- saw streams production --prefix api
15- saw watch production --prefix api --filter error` ,
12+ Long : "Saw is a fast, multipurpose tool for AWS CloudWatch Logs." ,
13+ Example : ` saw groups
14+ saw streams production
15+ saw watch production` ,
1616 Run : func (cmd * cobra.Command , args []string ) {
1717 cmd .HelpFunc ()(cmd , args )
1818 },
@@ -21,11 +21,11 @@ var sawCommand = &cobra.Command{
2121var awsConfig config.AWSConfiguration
2222
2323func init () {
24- sawCommand .AddCommand (groupsCommand )
25- sawCommand .AddCommand (streamsCommand )
26- sawCommand .AddCommand (versionCommand )
27- sawCommand .AddCommand (watchCommand )
28- sawCommand .AddCommand (getCommand )
29- sawCommand .PersistentFlags ().StringVar (& awsConfig .Region , "region" , "" , "override profile AWS region" )
30- sawCommand .PersistentFlags ().StringVar (& awsConfig .Profile , "profile" , "" , "override default AWS profile" )
24+ SawCommand .AddCommand (groupsCommand )
25+ SawCommand .AddCommand (streamsCommand )
26+ SawCommand .AddCommand (versionCommand )
27+ SawCommand .AddCommand (watchCommand )
28+ SawCommand .AddCommand (getCommand )
29+ SawCommand .PersistentFlags ().StringVar (& awsConfig .Region , "region" , "" , "override profile AWS region" )
30+ SawCommand .PersistentFlags ().StringVar (& awsConfig .Profile , "profile" , "" , "override default AWS profile" )
3131}
0 commit comments