-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
command expansions #3393
command expansions #3393
Conversation
only support filename val for now: support simple sh command like:
|
Just curious: does this quote the filename so that if you pass it to |
I think we can use |
FYI: This doesn't handle substitution in the keymap arguments. [keys.normal]
"C-s" = [":sh hx_rcs_write.sh '%val{filename}'", ":w"] # version control the previous and write out the new |
@trink , it shall work now, please take anther look, thanks! |
support %val {filename} %val {dirname} and %sh {cmd} now, we can also nest them like %sh { echo %val {dirname} }, also addressed the 'have to escape space' issue as @the-mikedavis suggested. |
} else if event == PromptEvent::Validate { | ||
cx.editor | ||
.set_error(format!("no such command: '{}'", parts[0])); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this return an error too?
for (i, &b) in str.as_bytes().iter().enumerate() { | ||
match char::from_u32(b as u32) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't we iterate over char directly instead? I think unicode might crash in this case when we are reading bytes within multiple bytes char.
Also, the count with unicode characters is incorrect now, as_bytes
may increment i
more times than the actual character length str.len
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the b
is a byte so that this won't crash.As we only use ascii chars in our patterns below, I didn't treat them as Unicode char, this shall work until we introduce other Unicode pattern beside %val
etc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If these patterns are coming from user input there's always a chance that they can be multi-byte, or even multi code-point "characters". Because of that you might want the parser to be aware / tolerant of it.
If that is the case then String.chars
probably still isn't enough and you'll need something more unicode aware if you're interested in knowing a particular characters index as a human would see it. See this note from the rust std library:
let y = "y̆";
let mut chars = y.chars();
assert_eq!(Some('y'), chars.next()); // not 'y̆'
The typical crate I've used / seen used is https://crates.io/crates/unicode-segmentation . Specifically for this implementation you could use grapheme_indices https://unicode-rs.github.io/unicode-segmentation/unicode_segmentation/trait.UnicodeSegmentation.html#tymethod.grapheme_indices .
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The returned index will always be in bounds (the enumerator and len are both byte based). Trying something like the following doesn't cause any issues
sh echo %val{𒀀𒀀𒀀𒀀𒀀𒀀𒀀}
// 4 byte char f0928080
I think this should remain as is.
However, downstream I am seeing something off in shellwords (some multi-byte characters are lost in the generated argument list, I am investigating it now but it is unrelated to this PR)
edit: #5738
let reg = Regex::new(r"%(\w+)\s*\{(.*)").unwrap(); | ||
reg.replace(args, |caps: ®ex::Captures| { | ||
let remaining = &caps[2]; | ||
let end = find_first_open_right_braces(remaining); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we auto-complete for users? I think %sh{echo hello
shouldn't work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, above command won't expand and will be treated literately . The auto-complete is a very nice to have feature, how about we adding it after this PR.
Co-authored-by: Ivan Tham <[email protected]>
_ => "".into(), | ||
}; | ||
let next = expand_args(editor, remaining.get(end + 1..).unwrap_or("")); | ||
format!("{rep} {next}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The added space between rep and next is a problem when you want to compose a single argument with the substitution. e.g.
:sh echo %val{filename},v
This currently produces two arguments "filename", ",v" instead of the desired "filename,v"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, will fix it once I have time.
for (i, &b) in str.as_bytes().iter().enumerate() { | ||
match char::from_u32(b as u32) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The returned index will always be in bounds (the enumerator and len are both byte based). Trying something like the following doesn't cause any issues
sh echo %val{𒀀𒀀𒀀𒀀𒀀𒀀𒀀}
// 4 byte char f0928080
I think this should remain as is.
However, downstream I am seeing something off in shellwords (some multi-byte characters are lost in the generated argument list, I am investigating it now but it is unrelated to this PR)
edit: #5738
Thanks, @QiBaobin I really liked this feature, with that I could build:
These scripts that I created are not perfect because I had to hard-code how to get the project dirname. Could we have something like Edit: Another useful variable is something like |
Hey guys, I got the nested commands working with %key{body} You can try the changes in the branch cmd-expansions of my fork. The output of the tests:
The bare-bones code: fn test(to_test: &str, expected: &str) {
let start = std::time::Instant::now();
println!("\x1b[33m[TEST]\x1b[0m {to_test} => {expected}");
let result = find_and_replace(to_test).unwrap_or_default();
assert_eq!(result, expected);
println!(
"\x1b[32m[PASSED {:2?}]\x1b[0m {result} == {expected}\n",
start.elapsed()
);
}
fn main() {
test("%val {filedir}", "filedir");
test("%val {filedir%val {aasdfasdf}}", "filediraasdfasdf");
test(
"%sh {rm %val{filedir},%val{filename}}",
"rm filedir,filename",
);
test(
"%sh {git blame %val{filename}:%val{linenumber}}",
"git blame filename:linenumber",
);
test(
":sh (%sh {cat %val{filename} | grep rust}) > %val{filedir}/test.txt",
":sh (cat filename | grep rust) > filedir/test.txt",
);
test(
":sh bash -c (%sh {(%sh {cat %val{filedir}/test.txt}) > %val{filedir}/../%val{filename}_test.txt})",
":sh bash -c ((cat filedir/test.txt) > filedir/../filename_test.txt)",
);
}
fn find_and_replace(input: &str) -> anyhow::Result<String> {
let regexp = regex::Regex::new(r"%(\w+)\s*\{([^{}]*(\{[^{}]*\}[^{}]*)*)\}").unwrap();
replace_all(®exp, input, |captures| {
let keyword = captures.get(1).unwrap().as_str();
let body = captures.get(2).unwrap().as_str();
match keyword {
"val" => Ok(String::from(body)),
"sh" => Ok(String::from(body)),
_ => anyhow::bail!("Unknown keyword {keyword}"),
}
})
}
fn replace_all(
regex: ®ex::Regex,
text: &str,
matcher: impl Fn(®ex::Captures) -> anyhow::Result<String>,
) -> anyhow::Result<String> {
let mut it = regex.captures_iter(text).peekable();
if it.peek().is_none() {
return Ok(String::from(text));
}
let mut new = String::with_capacity(text.len());
let mut last_match = 0;
for cap in it {
let m = cap.get(0).unwrap();
new.push_str(&text[last_match..m.start()]);
let replace = matcher(&cap)?;
new.push_str(&replace);
last_match = m.end();
}
new.push_str(&text[last_match..]);
replace_all(regex, &new, matcher)
} |
@ksdrar I found an issue. I was migrating all keybindings that I did using my version to your version and this one didn't work.
It is not expanding |
I think it should expand the most inner expressions first, and move to the next one only when there is nothing left to expand. For example:
Command: Expansion Steps:
Scripts:
|
@danillos Can you check if it's working now with the last commit? |
Yes, this example is now working.
|
@ksdrar could you open your changes as a new PR for replace this one? I could do that too. |
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
Based on: helix-editor#3393 --- Squashed commit of the following: commit 4e16272eb27fde410022785ffcdb6828ac61aee9 Merge: 07b109d 5ae30f1 Author: Jesús R <[email protected]> Date: Sat May 6 07:56:28 2023 -0600 Merge branch 'master' into cmd-expansions commit 07b109d Author: Jesús R <[email protected]> Date: Mon Apr 24 19:14:58 2023 -0600 fix: Not parsing sh body commit 8bf040f Author: Jesús R <[email protected]> Date: Sat Apr 22 22:46:17 2023 -0600 Use %key{body} commit f6fea44 Merge: ffb40de b7c62e2 Author: Jesús R <[email protected]> Date: Sat Apr 22 17:34:07 2023 -0600 Merge branch 'master' into cmd-expansions commit ffb40de Merge: 2be5d34 b9b4ed5 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:48:15 2023 -0600 Merge branch 'master' into cmd-expansions commit 2be5d34 Author: Jesús R <[email protected]> Date: Tue Apr 11 15:46:58 2023 -0600 Use #{} for variables and #key [] for commands commit 7e7c0dc Merge: 22d17f9 531b745 Author: Bob <[email protected]> Date: Wed Apr 5 09:11:13 2023 +0800 Merge branch 'master' into cmd-expansions commit 22d17f9 Author: Bob <[email protected]> Date: Thu Jan 26 09:43:13 2023 +0800 Update helix-term/src/commands/typed.rs Co-authored-by: Ivan Tham <[email protected]> commit 85d38a7 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:49:16 2023 +0800 remove command group function commit 784380f Merge: 6f6cb3c 64ec025 Author: Bob Qi <[email protected]> Date: Tue Jan 24 14:42:31 2023 +0800 Merge remote-tracking branch 'origin/master' commit 6f6cb3c Author: Bob Qi <[email protected]> Date: Mon Nov 21 10:39:52 2022 +0800 support commmand expansion
#3134