aboutsummaryrefslogtreecommitdiffstats
path: root/gdrive.go
diff options
context:
space:
mode:
authorPetter Rasmussen2016-01-23 22:38:45 +0100
committerPetter Rasmussen2016-01-23 22:38:45 +0100
commit2304f9ae29a490231b8ba38d346de0754c4a7fd4 (patch)
tree76e3eb520bbe1b30c1e3835ccc7d0fec9dbac3c9 /gdrive.go
parente6dd66c5722e37a4d2ea7000ce4d1f4090af9cc7 (diff)
downloadgdrive-2304f9ae29a490231b8ba38d346de0754c4a7fd4.tar.bz2
Give about import/export own handlers
Diffstat (limited to 'gdrive.go')
-rw-r--r--gdrive.go30
1 files changed, 17 insertions, 13 deletions
diff --git a/gdrive.go b/gdrive.go
index 4349b02..2980fa4 100644
--- a/gdrive.go
+++ b/gdrive.go
@@ -392,7 +392,7 @@ func main() {
},
&cli.Handler{
Pattern: "[global options] about [options]",
- Description: "Google drive metadata, quota usage, import/export formats",
+ Description: "Google drive metadata, quota usage",
Callback: aboutHandler,
Flags: cli.Flags{
"global options": globalFlags,
@@ -403,22 +403,26 @@ func main() {
Description: "Show size in bytes",
OmitValue: true,
},
- cli.BoolFlag{
- Name: "exportFormats",
- Patterns: []string{"--export"},
- Description: "Show supported export formats",
- OmitValue: true,
- },
- cli.BoolFlag{
- Name: "importFormats",
- Patterns: []string{"--import"},
- Description: "Show supported import formats",
- OmitValue: true,
- },
},
},
},
&cli.Handler{
+ Pattern: "[global options] about import",
+ Description: "Show supported import formats",
+ Callback: aboutImportHandler,
+ Flags: cli.Flags{
+ "global options": globalFlags,
+ },
+ },
+ &cli.Handler{
+ Pattern: "[global options] about export",
+ Description: "Show supported export formats",
+ Callback: aboutExportHandler,
+ Flags: cli.Flags{
+ "global options": globalFlags,
+ },
+ },
+ &cli.Handler{
Pattern: "version",
Description: "Print application version",
Callback: printVersion,