Skip to content

Commit

Permalink
Add apple keyword to match more artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
filiptibell committed Mar 28, 2024
1 parent 5992253 commit 7f8d3c6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/descriptor/os.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use std::env::consts::OS as CURRENT_OS;
#[rustfmt::skip]
const OS_KEYWORDS: [(OS, &[&str]); 3] = [
(OS::Windows, &["windows", "win32", "win64", "win-x86", "win-x64"]),
(OS::MacOS, &["macos", "osx", "darwin"]),
(OS::MacOS, &["macos", "osx", "darwin", "apple"]),
(OS::Linux, &["linux", "ubuntu", "debian"]),
];

Expand Down Expand Up @@ -92,6 +92,7 @@ mod tests {
assert_eq!(OS::detect("APP-macos-ARCH-VER"), Some(OS::MacOS));
assert_eq!(OS::detect("APP-osx-ARCH-VER"), Some(OS::MacOS));
assert_eq!(OS::detect("APP-darwin-ARCH-VER"), Some(OS::MacOS));
assert_eq!(OS::detect("APP-apple-ARCH-VER"), Some(OS::MacOS));
assert_eq!(OS::detect("APP-linux-ARCH-VER"), Some(OS::Linux));
assert_eq!(OS::detect("APP-ubuntu-ARCH-VER"), Some(OS::Linux));
assert_eq!(OS::detect("APP-debian-ARCH-VER"), Some(OS::Linux));
Expand Down

0 comments on commit 7f8d3c6

Please sign in to comment.