pub enum Distribution {
Ubuntu,
Debian,
Other(String),
}Expand description
Represents a Linux distribution
Variants§
Implementations§
Source§impl Distribution
impl Distribution
Sourcepub fn current() -> Result<Distribution, String>
pub fn current() -> Result<Distribution, String>
Get the current system’s distribution information
Sourcepub fn default_components(&self) -> Vec<&'static str>
pub fn default_components(&self) -> Vec<&'static str>
Get default components for this distribution
Sourcepub fn is_main_repository(&self, repo: &Repository) -> bool
pub fn is_main_repository(&self, repo: &Repository) -> bool
Check if a repository is a main distribution repository
Trait Implementations§
Source§impl Clone for Distribution
impl Clone for Distribution
Source§fn clone(&self) -> Distribution
fn clone(&self) -> Distribution
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Distribution
impl Debug for Distribution
Source§impl PartialEq for Distribution
impl PartialEq for Distribution
impl StructuralPartialEq for Distribution
Auto Trait Implementations§
impl Freeze for Distribution
impl RefUnwindSafe for Distribution
impl Send for Distribution
impl Sync for Distribution
impl Unpin for Distribution
impl UnwindSafe for Distribution
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more