Skip to content

Commit

Permalink
Turn off flags which arent implemented yet
Browse files Browse the repository at this point in the history
  • Loading branch information
boyter committed Mar 4, 2020
1 parent 03a414a commit 50619a2
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 52 deletions.
100 changes: 49 additions & 51 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,14 @@ func main() {
false,
"attempts to find the root of this repository recursively looking for .git or .hg",
)
flags.StringSliceVar(
&processor.PathDenylist,
"exclude-dir",
[]string{".git", ".hg", ".svn"},
"directories to exclude",
)

// the below flags we want but are not enabled as yet

//flags.BoolVar(
// &processor.Debug,
Expand All @@ -117,29 +125,21 @@ func main() {
// 100,
// "number of matching results to process",
//)
//flags.StringVarP(
// &processor.Format,
// "format",
// "f",
// "text",
// "set output format [text, json]",
//)


flags.StringSliceVar(
&processor.PathDenylist,
"exclude-dir",
[]string{".git", ".hg", ".svn"},
"directories to exclude",
)
flags.StringVarP(
&processor.Format,
"format",
"f",
"text",
"set output format [text, json]",
)

flags.StringVarP(
&processor.FileOutput,
"output",
"o",
"",
"output filename (default stdout)",
)
//flags.StringVarP(
// &processor.FileOutput,
// "output",
// "o",
// "",
// "output filename (default stdout)",
//)
//flags.BoolVarP(
// &processor.Trace,
// "trace",
Expand All @@ -154,35 +154,33 @@ func main() {
// false,
// "verbose output",
//)
flags.BoolVar(
&processor.IncludeMinified,
"include-min",
false,
"include minified files",
)

flags.IntVar(
&processor.MinifiedLineByteLength,
"min-line-length",
255,
"number of bytes per average line for file to be considered minified",
)
flags.StringSliceVarP(
&processor.LocationExcludePattern,
"exclude-pattern",
"x",
[]string{},
"file locations matching this pattern ignoring case will be ignored",
)

flags.BoolVarP(
&processor.CaseSensitive,
"case-sensitive",
"c",
false,
"make the search case sensitive",
)

//flags.BoolVar(
// &processor.IncludeMinified,
// "include-min",
// false,
// "include minified files",
//)
//
//flags.IntVar(
// &processor.MinifiedLineByteLength,
// "min-line-length",
// 255,
// "number of bytes per average line for file to be considered minified",
//)
//flags.StringSliceVarP(
// &processor.LocationExcludePattern,
// "exclude-pattern",
// "x",
// []string{},
// "file locations matching this pattern ignoring case will be ignored",
//)
//flags.BoolVarP(
// &processor.CaseSensitive,
// "case-sensitive",
// "c",
// false,
// "make the search case sensitive",
//)

if err := rootCmd.Execute(); err != nil {
os.Exit(1)
Expand Down
2 changes: 1 addition & 1 deletion processor/processor.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"strings"
)

var Version = "0.2.0 alpha"
var Version = "0.5.0 alpha"

// Clean up the input to avoid searching for spaces etc...
// Take the string cut it up, lower case everything except
Expand Down

0 comments on commit 50619a2

Please sign in to comment.