Skip to content

bread-graphics/detect-desktop-environment

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Detect Desktop Environment

This crate helps you to detect the current desktop environment. It was inspired by the detectDE function from xdg-util.

This library is stable. If you have an issue or want to add a desktop environment, open a Github issue or send a PR. Please also report possible naming issues.

Installation

Usage

extern crate detect_desktop_environment;

use detect_desktop_environment::{DesktopEnvironment, detect};

fn main() {
  let de: DesktopEnvironment = detect();
  println!("{:?}", de);
}

This library exposes two symbols: the detect function and it return value: the DesktopValue enum. All the variants are listed below in the "Supported environments" section.

Supported environments

Name Thumbnail
Cinnamon Cinnamon
Enlightenment Enlightenment
Gnome Gnome
Kde Kde
Lxde Lxde
Lxqt Lxqt
MacOs MacOs
Mate Mate
Unity Unity
Windows Windows
Xfce Xfce
Unknown

About

Detect the desktop environment

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 100.0%