diff options
Diffstat (limited to 'src/options.go')
| -rw-r--r-- | src/options.go | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/options.go b/src/options.go index e1dba299..b11328e5 100644 --- a/src/options.go +++ b/src/options.go @@ -266,6 +266,17 @@ func parseOptions(opts *Options, allArgs []string) { } } } + + // If we're not using extended search mode, --nth option becomes irrelevant + // if it contains the whole range + if opts.Mode == ModeFuzzy || len(opts.Nth) == 1 { + for _, r := range opts.Nth { + if r.begin == rangeEllipsis && r.end == rangeEllipsis { + opts.Nth = make([]Range, 0) + return + } + } + } } // ParseOptions parses command-line options |
