xdg-utils
xdg-utils is a set of tools that allows applications to easily integrate with the desktop environment of the user, regardless of the specific desktop environment that the user runs.
License model
- Free • Open Source
Platforms
- Linux
Features
- System Information
xdg-utils News & Activities
Recent News
Recent activities
- forcemajore liked xdg-utils
xdg-utils information
What is xdg-utils?
xdg-utils is a set of tools that allows applications to easily integrate with the desktop environment of the user, regardless of the specific desktop environment that the user runs.
About half of the tools focus on tasks commonly required during the installation of a desktop application and the other half focuses on integration with the desktop environment while the application is running.
xdg-desktop-menu Install desktop menu items xdg-desktop-icon Install icons to the desktop xdg-icon-resource Install icon resources xdg-mime Query information about file type handling and install descriptions for new file types xdg-open Open a file or URL in the user's preferred application xdg-email Send mail using the user's preferred e-mail composer xdg-screensaver Control the screensaver
Comments and Reviews
Don't forget about file:// protocol when working with xdg-open: xdg-open file:///usr/share/dict
Useful read for advanced users and developers: https://specifications.freedesktop.org/mime-apps-spec/mime-apps-spec-1.0.1.html.
Defaults with Ubuntu 20.04.4 LTS desktop:
XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/etc/xdg XDG_CURRENT_DESKTOP=ubuntu:GNOME XDG_DATA_DIRS=/usr/share/ubuntu:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop XDG_MENU_PREFIX=gnome- XDG_RUNTIME_DIR=/run/user/1000 XDG_SESSION_CLASS=user XDG_SESSION_DESKTOP=ubuntu XDG_SESSION_TYPE=x11
Use these commands in order to get name of .desktop file.
xdg-mime query default $(xdg-mime query filetype "path")