Skip to repository content

tenant.openagents/omega

No repository description is available.

OpenAgents Git authority 2026-07-28T05:38:06.627Z Public web read
NIP-34 coordinate30617:7649603503856e5148d571eac2766b288a8ff1e9e35d380337a1d2b0015b4f92:omega
MaintainersHidden in public view
References2 branches · 1 tag
Read-only clonegit clone https://openagents.com/git/tenant.openagents/omega.git
Browse files

platform.rs

26 lines · 685 B · rust
1/// The platform style to use when rendering UI.
2///
3/// This can be used to abstract over platform differences.
4#[derive(Debug, PartialEq, Eq, PartialOrd, Ord, Hash, Clone, Copy)]
5pub enum PlatformStyle {
6    /// Display in macOS style.
7    Mac,
8    /// Display in Linux style.
9    Linux,
10    /// Display in Windows style.
11    Windows,
12}
13
14impl PlatformStyle {
15    /// Returns the [`PlatformStyle`] for the current platform.
16    pub const fn platform() -> Self {
17        if cfg!(any(target_os = "linux", target_os = "freebsd")) {
18            Self::Linux
19        } else if cfg!(target_os = "windows") {
20            Self::Windows
21        } else {
22            Self::Mac
23        }
24    }
25}
26
Served at tenant.openagents/omega Member data and write actions are omitted.