From 353436a0312b6eaaec99d4f6ffe54068d26585bd Mon Sep 17 00:00:00 2001 From: Vincent Batts Date: Thu, 17 Nov 2016 22:00:23 -0500 Subject: [PATCH] main: group flag variables Signed-off-by: Vincent Batts --- cmd/gomtree/main.go | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/cmd/gomtree/main.go b/cmd/gomtree/main.go index 0d3d488..9461638 100644 --- a/cmd/gomtree/main.go +++ b/cmd/gomtree/main.go @@ -15,11 +15,14 @@ import ( ) var ( - flCreate = flag.Bool("c", false, "create a directory hierarchy spec") - flFile = flag.String("f", "", "directory hierarchy spec to validate") - flPath = flag.String("p", "", "root path that the hierarchy spec is relative to") - flAddKeywords = flag.String("K", "", "Add the specified (delimited by comma or space) keywords to the current set of keywords") - flUseKeywords = flag.String("k", "", "Use the specified (delimited by comma or space) keywords as the current set of keywords") + // Flags common with mtree(8) + flCreate = flag.Bool("c", false, "create a directory hierarchy spec") + flFile = flag.String("f", "", "directory hierarchy spec to validate") + flPath = flag.String("p", "", "root path that the hierarchy spec is relative to") + flAddKeywords = flag.String("K", "", "Add the specified (delimited by comma or space) keywords to the current set of keywords") + flUseKeywords = flag.String("k", "", "Use the specified (delimited by comma or space) keywords as the current set of keywords") + + // Flags unique to gomtree flListKeywords = flag.Bool("list-keywords", false, "List the keywords available") flResultFormat = flag.String("result-format", "bsd", "output the validation results using the given format (bsd, json, path)") flTar = flag.String("T", "", "use tar archive to create or validate a directory hierarchy spec (\"-\" indicates stdin)")