diff options
author | Andrew Gallant <jamslam@gmail.com> | 2016-12-06 17:29:34 -0500 |
---|---|---|
committer | Andrew Gallant <jamslam@gmail.com> | 2016-12-06 17:29:34 -0500 |
commit | d66812102b6184a0dd7d168a3afe2dbf209841cb (patch) | |
tree | aabffcaadc714bbabe7a01a2cb8ec279db2a655a /src | |
parent | 86f8c3c8183a67ad3f4ced334b2d05373c76e985 (diff) |
Fix leading hypen bug by updating clap.
Fixes #270
Diffstat (limited to 'src')
-rw-r--r-- | src/app.rs | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -1,6 +1,6 @@ use std::collections::HashMap; -use clap::{App, AppSettings, Arg}; +use clap::{App, AppSettings, Arg, ArgSettings}; const ABOUT: &'static str = " ripgrep (rg) recursively searches your current directory for a regex pattern. @@ -74,6 +74,7 @@ fn app<F>(next_line_help: bool, doc: F) -> App<'static, 'static> .arg(arg("path").multiple(true)) .arg(flag("regexp").short("e") .takes_value(true).multiple(true).number_of_values(1) + .set(ArgSettings::AllowLeadingHyphen) .value_name("pattern")) .arg(flag("files") // This should also conflict with `pattern`, but the first file |