mirror of https://github.com/helix-editor/helix
add missing bufferline option
parent
0d509d619b
commit
c1da27bbab
|
@ -43,7 +43,6 @@ use std::{
|
||||||
borrow::Cow,
|
borrow::Cow,
|
||||||
collections::HashMap,
|
collections::HashMap,
|
||||||
error::Error,
|
error::Error,
|
||||||
ops::Deref,
|
|
||||||
path::PathBuf,
|
path::PathBuf,
|
||||||
sync::{atomic::AtomicBool, Mutex, MutexGuard, RwLock, RwLockReadGuard},
|
sync::{atomic::AtomicBool, Mutex, MutexGuard, RwLock, RwLockReadGuard},
|
||||||
time::Duration,
|
time::Duration,
|
||||||
|
@ -2638,10 +2637,22 @@ impl HelixConfiguration {
|
||||||
self.store_config(app_config);
|
self.store_config(app_config);
|
||||||
}
|
}
|
||||||
|
|
||||||
fn bufferline(&self, config: BufferLine) {
|
fn bufferline(&self, buffer_config: SteelVal) -> anyhow::Result<()> {
|
||||||
|
let config = match buffer_config {
|
||||||
|
SteelVal::StringV(s) | SteelVal::SymbolV(s) => match s.as_str() {
|
||||||
|
"never" => BufferLine::Never,
|
||||||
|
"always" => BufferLine::Always,
|
||||||
|
"multiple" => BufferLine::Multiple,
|
||||||
|
other => anyhow::bail!("Unrecognized bufferline option: {}", other),
|
||||||
|
},
|
||||||
|
other => anyhow::bail!("Unrecognized bufferline option: {}", other),
|
||||||
|
};
|
||||||
|
|
||||||
let mut app_config = self.load_config();
|
let mut app_config = self.load_config();
|
||||||
app_config.editor.bufferline = config;
|
app_config.editor.bufferline = config;
|
||||||
self.store_config(app_config);
|
self.store_config(app_config);
|
||||||
|
|
||||||
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
fn indent_guides(&self, config: IndentGuidesConfig) {
|
fn indent_guides(&self, config: IndentGuidesConfig) {
|
||||||
|
|
Loading…
Reference in New Issue