Add Candidate type for case-insensitive completion, shopt_group macro, escape fixes, and vi mode tweaks
This commit is contained in:
@@ -31,7 +31,7 @@ use crate::{
|
||||
},
|
||||
prelude::*,
|
||||
readline::{
|
||||
complete::{BashCompSpec, CompSpec},
|
||||
complete::{BashCompSpec, Candidate, CompSpec},
|
||||
keys::KeyEvent,
|
||||
markers,
|
||||
},
|
||||
@@ -1001,6 +1001,13 @@ impl From<Vec<String>> for Var {
|
||||
}
|
||||
}
|
||||
|
||||
impl From<Vec<Candidate>> for Var {
|
||||
fn from(value: Vec<Candidate>) -> Self {
|
||||
let as_strs = value.into_iter().map(|c| c.0).collect::<Vec<_>>();
|
||||
Self::new(VarKind::Arr(as_strs.into()), VarFlags::NONE)
|
||||
}
|
||||
}
|
||||
|
||||
impl From<&[String]> for Var {
|
||||
fn from(value: &[String]) -> Self {
|
||||
let mut new = VecDeque::new();
|
||||
|
||||
Reference in New Issue
Block a user