fixup! feat: add YAZI_LEVEL env variable for shells

This commit is contained in:
István Donkó 2024-01-15 17:08:21 +01:00
parent 8c4f9308c6
commit ab0019f8f4

View file

@ -36,7 +36,7 @@ pub fn shell(opt: ShellOpt) -> Result<Child> {
"YAZI_LEVEL", "YAZI_LEVEL",
(env::var("YAZI_LEVEL") (env::var("YAZI_LEVEL")
.ok() .ok()
.and_then(|lvl_str| lvl_str.parse::<i32>().ok()) .and_then(|lvl_str| lvl_str.parse::<u32>().ok())
.unwrap_or(0) .unwrap_or(0)
+ 1) + 1)
.to_string(), .to_string(),