diff --git a/Cargo.lock b/Cargo.lock index 3b4a591..3e4ff5f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -51,7 +51,7 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bulkrename" -version = "0.1.0" +version = "0.1.1" dependencies = [ "ansi_term", "anyhow", diff --git a/Cargo.toml b/Cargo.toml index f63420d..0f0e0ba 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "bulkrename" -version = "0.1.0" +version = "0.1.1" edition = "2021" readme = "README.md" diff --git a/chris_plugin_info.json b/chris_plugin_info.json index 01f53c5..32f2742 100644 --- a/chris_plugin_info.json +++ b/chris_plugin_info.json @@ -4,34 +4,34 @@ { "name": "filter", "type": "str", - "optional": true, + "optional": false, "flag": "--filter", "short_flag": "-f", "action": "store", "help": "Input path filter. Paths which do not match this regex are excluded.", - "default": ".*", + "default": null, "ui_exposed": true }, { "name": "expression", "type": "str", - "optional": true, + "optional": false, "flag": "--expression", "short_flag": "-e", "action": "store", "help": "Regular expression to match paths. See https://docs.rs/regex/1.5.5/regex/#syntax", - "default": "(.*)", + "default": null, "ui_exposed": true }, { "name": "replacement", "type": "str", - "optional": true, + "optional": false, "flag": "--replace", "short_flag": "-r", "action": "store", "help": "Replacement string with capture groups. See https://docs.rs/regex/1.5.5/regex/#grouping-and-flags", - "default": "\\1", + "default": null, "ui_exposed": true } ], @@ -42,7 +42,7 @@ "description": "A ChRIS plugin to rename paths using regex", "documentation": "https://github.com/FNNDSC/pl-bulk-rename", "license": "MIT", - "version": "0.1.0", + "version": "0.1.1", "selfpath": "/usr/local/bin", "selfexec": "bulkrename", "execshell": "/docker-entrypoint.sh", diff --git a/src/main.rs b/src/main.rs index 44b7af7..b7c2171 100644 --- a/src/main.rs +++ b/src/main.rs @@ -19,15 +19,15 @@ disable_help_subcommand = true )] struct Cli { /// Input path filter. Paths which do not match this regex are excluded. - #[clap(short, long, default_value = ".*")] + #[clap(short, long)] filter: String, /// Regular expression to match paths - #[clap(short, long, default_value = "(.*)")] + #[clap(short, long)] expression: String, /// Replacement string with capture groups - #[clap(short, long, default_value = "$0")] + #[clap(short, long)] replace: String, /// Silence output