mirror of
https://github.com/TECHNOFAB11/pay-respects.git
synced 2025-12-12 14:30:10 +01:00
fix: missing space in opts
This commit is contained in:
parent
25e8f5875b
commit
3460d66aac
3 changed files with 5 additions and 3 deletions
|
|
@ -30,7 +30,9 @@ pub fn opts(suggest: &mut String, last_command: &mut String, opt_list: &mut Vec<
|
||||||
let regex = opt.trim();
|
let regex = opt.trim();
|
||||||
let current_tag = tag(tag_name, replace_tag);
|
let current_tag = tag(tag_name, replace_tag);
|
||||||
|
|
||||||
opt_list.push((current_tag.clone(), opt_regex(regex, last_command)));
|
let opts = format!(" {}", opt_regex(regex, last_command));
|
||||||
|
|
||||||
|
opt_list.push((current_tag.clone(), opts));
|
||||||
suggest.replace_range(placeholder, ¤t_tag);
|
suggest.replace_range(placeholder, ¤t_tag);
|
||||||
|
|
||||||
replace_tag += 1;
|
replace_tag += 1;
|
||||||
|
|
|
||||||
|
|
@ -43,7 +43,7 @@ pub fn opts(
|
||||||
let current_tag = tag(tag_name, replace_tag);
|
let current_tag = tag(tag_name, replace_tag);
|
||||||
let token_tag: TokenStream2 = format!("{}{}", tag_name, replace_tag).parse().unwrap();
|
let token_tag: TokenStream2 = format!("{}{}", tag_name, replace_tag).parse().unwrap();
|
||||||
let command = quote! {
|
let command = quote! {
|
||||||
let #token_tag = opt_regex(#regex, &mut last_command);
|
let #token_tag = format!(" {}", opt_regex(#regex, &mut last_command));
|
||||||
};
|
};
|
||||||
opt_list.push(command);
|
opt_list.push(command);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@ suggest = [
|
||||||
|
|
||||||
[[match_err]]
|
[[match_err]]
|
||||||
pattern = [
|
pattern = [
|
||||||
"cannot create directory",
|
"cannot create",
|
||||||
]
|
]
|
||||||
suggest = [
|
suggest = [
|
||||||
'''
|
'''
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue