Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add support for Bluefin Linux #394

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions os_info/src/info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,7 @@ mod tests {
Type::Android,
Type::Arch,
Type::Artix,
Type::Bluefin,
Type::CachyOS,
Type::CentOS,
Type::Debian,
Expand Down
12 changes: 12 additions & 0 deletions os_info/src/linux/file_release.rs
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@
"arch" => Some(Type::Arch),
"archarm" => Some(Type::Arch),
"artix" => Some(Type::Artix),
"bluefin" => Some(Type::Bluefin),
"cachyos" => Some(Type::CachyOS),
"centos" => Some(Type::CentOS),
//"clear-linux-os" => ClearLinuxOS
Expand All @@ -125,7 +126,7 @@
"ol" => Some(Type::OracleLinux),
"opensuse" => Some(Type::openSUSE),
"opensuse-leap" => Some(Type::openSUSE),
"opensuse-microos" => Some(Type::openSUSE),

Check warning on line 129 in os_info/src/linux/file_release.rs

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (microos)
"opensuse-tumbleweed" => Some(Type::openSUSE),
//"rancheros" => RancherOS
//"raspbian" => Raspbian
Expand Down Expand Up @@ -304,6 +305,17 @@
assert_eq!(info.codename, None);
}

#[test]
fn bluefin_os_release() {
let root = "src/linux/tests/Bluefin";

let info = retrieve(&DISTRIBUTIONS, root).unwrap();
assert_eq!(info.os_type(), Type::Bluefin);
assert_eq!(info.version, Version::Semantic(41, 0, 0));
assert_eq!(info.edition, None);
assert_eq!(info.codename, None);
}

#[test]
fn centos_7_os_release() {
let root = "src/linux/tests/CentOS_7";
Expand Down Expand Up @@ -662,7 +674,7 @@
}

#[test]
fn cachy_os_release() {

Check warning on line 677 in os_info/src/linux/file_release.rs

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (cachy)
let root = "src/linux/tests/CachyOS";

let info = retrieve(&DISTRIBUTIONS, root).unwrap();
Expand Down
1 change: 1 addition & 0 deletions os_info/src/linux/lsb_release.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ pub fn get() -> Option<Info> {
Some("Amazon") | Some("AmazonAMI") => Type::Amazon,
Some("Arch") => Type::Arch,
Some("Artix") => Type::Artix,
Some("Bluefin") => Type::Bluefin,
Some("cachyos") => Type::CachyOS,
Some("CentOS") => Type::CentOS,
Some("Debian") => Type::Debian,
Expand Down
1 change: 1 addition & 0 deletions os_info/src/linux/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ mod tests {
| Type::Amazon
| Type::Arch
| Type::Artix
| Type::Bluefin
| Type::CachyOS
| Type::CentOS
| Type::Debian
Expand Down
24 changes: 24 additions & 0 deletions os_info/src/linux/tests/Bluefin/etc/os-release
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
NAME="Bluefin"
VERSION="41.20250119.1 (Silverblue)"
RELEASE_TYPE=stable
ID=bluefin
ID_LIKE="fedora"
VERSION_ID=41
VERSION_CODENAME="Archaeopteryx"
PLATFORM_ID="platform:f41"
PRETTY_NAME="Bluefin (Version: 41.20250119.1 / FROM Fedora Silverblue 41)"
ANSI_COLOR="0;38;2;60;110;180"
LOGO=fedora-logo-icon
CPE_NAME="cpe:/o:universal-blue:bluefin:41"
DEFAULT_HOSTNAME="bluefin"
HOME_URL="https://projectbluefin.io"
DOCUMENTATION_URL="https://docs.projectbluefin.io"
SUPPORT_URL="https://github.com/ublue-os/bluefin/issues/"
BUG_REPORT_URL="https://github.com/ublue-os/bluefin/issues/"
SUPPORT_END=2025-12-15
VARIANT="Silverblue"
VARIANT_ID=bluefin-dx
OSTREE_VERSION='41.20250119.1'
BUILD_ID="36c6eef"
IMAGE_ID="bluefin-dx"
IMAGE_VERSION="41.20250119.1"
4 changes: 4 additions & 0 deletions os_info/src/os_type.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ pub enum Type {
Arch,
/// Artix Linux (<https://en.wikipedia.org/wiki/Artix_Linux>).
Artix,
/// Bluefin (<https://projectbluefin.io>).
Bluefin,
/// CachyOS (<https://en.wikipedia.org/wiki/Arch_Linux#Derivatives>).
CachyOS,
/// CentOS (<https://en.wikipedia.org/wiki/CentOS>).
Expand Down Expand Up @@ -122,6 +124,7 @@ impl Display for Type {
Type::AlmaLinux => write!(f, "AlmaLinux"),
Type::Amazon => write!(f, "Amazon Linux AMI"),
Type::Arch => write!(f, "Arch Linux"),
Type::Bluefin => write!(f, "Bluefin"),
Type::CachyOS => write!(f, "CachyOS Linux"),
Type::Artix => write!(f, "Artix Linux"),
Type::DragonFly => write!(f, "DragonFly BSD"),
Expand Down Expand Up @@ -169,6 +172,7 @@ mod tests {
(Type::Android, "Android"),
(Type::Arch, "Arch Linux"),
(Type::Artix, "Artix Linux"),
(Type::Bluefin, "Bluefin"),
(Type::CachyOS, "CachyOS Linux"),
(Type::CentOS, "CentOS"),
(Type::Debian, "Debian"),
Expand Down
Loading