Skip to content

Commit c1048de

Browse files
authored
feat: support for Android platform in the for qualifier of opener (#2041)
1 parent 196a46c commit c1048de

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

Diff for: yazi-config/src/open/opener.rs

+3-5
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,9 @@ pub struct Opener {
1313
impl Opener {
1414
pub fn take(mut self) -> Option<Self> {
1515
if let Some(for_) = self.for_.take() {
16-
match for_.as_bytes() {
17-
b"unix" if cfg!(unix) => {}
18-
b"windows" if cfg!(windows) => {}
19-
b"linux" if cfg!(target_os = "linux") => {}
20-
b"macos" if cfg!(target_os = "macos") => {}
16+
match for_.as_str() {
17+
"unix" if cfg!(unix) => {}
18+
os if os == std::env::consts::OS => {}
2119
_ => return None,
2220
}
2321
}

0 commit comments

Comments
 (0)