Questions tagged [xdg]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer
16 views

Make Nemo show another name for a folder

I know about that xdg-user-dir stuff that helps make home subdirs in desired language. My locale is Russian and the system created 'download', 'documents', etc dirs in Russian language, and Nemo shows ...
Dmitry Arestov's user avatar
0 votes
0 answers
20 views

XDG_* environment variables not set in graphical login

When I login into one of the virtual consoles I have those environment variables XDG_RUNTIME_DIR XDG_SEAT XDG_SESSION_CLASS XDG_SESSION_ID XDG_SESSION_TYPE XDG_VTNR correctly set. On the other hand if ...
gboffi's user avatar
  • 1,362
1 vote
0 answers
209 views

Correct way to launch xdg desktop portal under bare WM setup?

Context I'm running Void Linux with X11. I'm not using any desktop environment or display manager. I simply type startx from tty to launch X11, and ~/.xinitrc launches BSPWM, polybar, and all the ...
renzev's user avatar
  • 111
0 votes
0 answers
127 views

Enabling screen sharing in Wayland on Rocky 8 in Gnome

I'm trying to get screen sharing to work on a machine running Rocky 8.8 and using Gnome as its desktop environment using Wayland. The screen sharing tool I'm using is screego, which runs in a web ...
dutsnekcirf's user avatar
2 votes
1 answer
300 views

Chromium doesn't open file dialog

When using chromium, the open or save file dialogs don't work. Examples: attaching a file or trying to download the attachment. I click them, nothing happens, nothing pops up. When running Firefox, ...
dabljues's user avatar
  • 123
1 vote
0 answers
71 views

Design .desktop File to Launch the Default Terminal Emulator with Arguments

I'd like to be able to open text and source code files in neovim (or any other terminal-based text editor) when an XDG-compatible GUI application asks with which application to open that file. For now,...
Marcus Müller's user avatar
0 votes
1 answer
494 views

What to store in XDG_DATA_HOME?

I'm reading up on the XDG Base Directory Specification, but I'm having some trouble understanding what exactly the $XDG_DATA_HOME is for. The specification mentions the following: There is a single ...
PieterV's user avatar
  • 125
1 vote
0 answers
582 views

How to switch to a different xdg-desktop-portal to have a different file picker?

I am using nemo as my default file and desktop manager using How to set Nemo as the default file manager in Ubuntu? In brief it looks like: sudo apt install nemo xdg-mime default nemo.desktop inode/...
Ahmad Ismail's user avatar
  • 2,648
3 votes
1 answer
893 views

How to switch to a different xdg-desktop-portal?

In my machine I, have multiple xdg-desktop-portal $ ls -la /usr/share/xdg-desktop-portal/portals .rw-r--r-- 100 root 23 Mar 14:48 gnome-keyring.portal .rw-r--r-- 99 root 20 Mar 02:25 gnome-shell....
Ahmad Ismail's user avatar
  • 2,648
5 votes
2 answers
2k views

Which xdg-desktop-portal am I currently using?

On my machine, I have multiple xdg-desktop-portal instances: $ ls -la /usr/share/xdg-desktop-portal/portals .rw-r--r-- 100 root 23 Mar 14:48 gnome-keyring.portal .rw-r--r-- 99 root 20 Mar 02:25 gnome-...
Ahmad Ismail's user avatar
  • 2,648
2 votes
0 answers
5k views

'/var/lib/flatpak/exports/share' is not in the search path set by the XDG_DATA_HOME and XDG_DATA_DIRS

Weird one, when I update flatpaks I get the following message in terminal: Note that '/var/lib/flatpak/exports/share' is not in the search path set by the XDG_DATA_HOME and XDG_DATA_DIRS environment ...
Geoff's user avatar
  • 43
0 votes
1 answer
1k views

Setting default file manager and locating a file with the default file manager

Please don't mark it as duplicated before reading my question. I know that there already are those questions, but the existing answer did not work as expected, and that is why I am asking this ...
Damn Vegetables's user avatar
2 votes
1 answer
706 views

google-chrome-stable not respecting xdg-open

I have a file downloaded using google-chrome-stable in ~/Downloads/video.mkv, but clicking the file in Chrome's downloads page somehow opens the file in Firefox instead of my default video player. ...
Kyle Richards's user avatar
1 vote
1 answer
2k views

Wayland Issue on FreeBSD

The Problem Hello, I am completely new to FreeBSD and relatively new to UNIX systems in general. I am following the FreeBSD Handbook, and loving it so far. My goal is to install river tiling window ...
Vladimir's user avatar
  • 169
1 vote
1 answer
334 views

Bridge dbus service to another bus

This is the situation: I have NetworkManager running on the host system. I have systemd and dbus running in a privileged Docker container. I want nmcli in the container to access the NetworkManager ...
Christian Stewart's user avatar
1 vote
1 answer
331 views

How should I handle two seemingly conflicting XDG Desktop Entry requirements?

According to my understanding of the File Naming section in the XDG Desktop Entry Specification, I should name my .desktop file following reverse-DNS notation: The name of the desktop entry should ...
Tenders McChiken's user avatar
1 vote
0 answers
159 views

On running xdg-settings get default-we-browser, I get the following message "unknown desktop environment"

I am running an R script that tries to open a link on the linux server. But on running the script, I get the following error xdg-open: no method available for opening 'https://unix.stackexchange.com/' ...
Narayan Shubha's user avatar
1 vote
1 answer
467 views

xdg-screensaver lock returns exit code 4 even though it worked

On an up to date openSUSE Tumbleweed install with KDE, running xdg-screensaver lock works (as in, the screen is locked just as if I'd done so through the UI), but it returns exit code 4, which ...
Mark Raymond's user avatar
1 vote
1 answer
4k views

How can I find the value of $XDG_CONFIG_HOME, $XDG_CONFIG_HOME, $XDG_STATE_HOME, etc in a Bash script?

This seems like a simple question that every application developer would have, but I can't find the answer. Per the latest XDG Basedir Spec, there are many directories that should be defined in ...
Dr-Bracket's user avatar
1 vote
2 answers
240 views

Where to put personal scripts according to XDG basedir spec?

I have a number of self-written scripts on my PC. I want to put these in the correct spot in my homedir according to the XDG Basedir spec. But I also want to backup these scripts in an clear and ...
PieterV's user avatar
  • 125
2 votes
1 answer
318 views

changing default program that opens a file using xdg-mime

I want to change the default program that opens video/mp4 files using xdg-mime from vlc.desktop to the firefox browser, firefox-firefox.desktop. I tried following the instructions given here however I ...
Mathew's user avatar
  • 73
1 vote
1 answer
616 views

XDG autostart order - how to control it?

When logging into my XFCE session, there are several "things" started via the XDG autostart mechanism. Is it possible to control the order in which applications start, or having some sort of ...
Jurc192's user avatar
  • 11
1 vote
1 answer
997 views

What is "New Virtual Output" in kde screen share (portal) dialog?

In kde wayland when you choose the pipewire source in obs, you get the Desktop Portal dialog that allows you to choose one of your screens or a "Full Workspace". But also there is an option &...
Ashark's user avatar
  • 889
4 votes
0 answers
620 views

default-url-scheme-handler not implemented for xfce

I run this code on kali linux: xdg-settings set default-url-scheme-handler https google-chrome.desktop I got this error: xdg-settings: default-url-scheme-handler not implemented for xfce how can I ...
Yilmaz's user avatar
  • 339
4 votes
1 answer
3k views

Where/How are the XDG_*_DIR user directory variables supposed to be set?

I'm referring to: https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html I have the following files in my .config directory: ~/.config/user-dirs.dirs: # ... XDG_DOWNLOAD_DIR=&...
anick's user avatar
  • 495
0 votes
2 answers
943 views

How to make Mozilla Firefox to follow the Freedesktop XDG specification?

I want to use the XDG specification to avoid cluttering in my $HOME directory in Arch Linux. Right now, Firefox version 101 created a $HOME/.mozilla directory, which I want to place somewhere else. So,...
Thesevs's user avatar
  • 87
1 vote
1 answer
326 views

Xdg-Mime won't change default application for .xopp (Xournalpp) files

I'm trying to change the default application for the filetype .xopp, which is a file for the xournalpp application. I currently ran the following commands: xdg-mime query filetype 2022-06-09/note.xopp ...
SingularisArt's user avatar
2 votes
1 answer
3k views

$XDG_CACHE_HOME vs. $XDG_STATE_HOME

Based on the XDG Base Directory Spacifications, $XDG_STATE_HOME should store history and log of the programs. But it is very common to see UNIX programs storing these kind of stuff at $XDG_CACHE_HOME, ...
Rubem Pacelli's user avatar
3 votes
1 answer
653 views

Firefox is already running ... error, but only from MS Teams

Whenever I click an HTTP(S) link in my desktop Teams client it hangs for about 5 seconds, then I get an error saying: "Firefox is already running, but is not responding. To use Firefox, you must ...
Scott Tiger's user avatar
2 votes
1 answer
656 views

Custom mime type for directories

Is it possible to make a custom mime type for directories (inode/directory)? Just like what MacOS does with *.app folders (app bundle) which make it possible to open them in another program.
Bytez's user avatar
  • 21
3 votes
1 answer
1k views

XDG_DATA_DIRS env variable using two separator types in fish shell

After doing an OS upgrade (opensuse leap 15.2 -> 15.3), my XDG setup broke. Among other things, my XDG_DATA_DIR env var uses two different value separators: : and . Current XDG_DATA_DIRS value: /...
Bernard Halas's user avatar
1 vote
1 answer
594 views

Make cron inherit XDG_RUNTIME_DIR

I have a cron job that runs emacsclient which requires that XDG_RUNTIME_DIR to be set. I can set the variable to something like /run/user/1000 in the crontab but then this assumes that the owner of ...
Tohiko's user avatar
  • 307
-1 votes
1 answer
435 views

Arch Linux: Is it possible to configure chromium to be my default browser for only a single website?

xdg-settings get default-web-browser produces firefox.desktop. This is what I want in almost every case. For a single website I want links to open in chromium.
Zach LeFevre's user avatar
2 votes
0 answers
136 views

Xfce4: How to decide which application to open the url based on patterns

The system has a bunch of browsers (like Chromium and Brave). All urls are to be opened by Chromium. So brave is not the default application for that. However, I want youtube links to be opened by ...
mrahimygk's user avatar
  • 121
5 votes
2 answers
9k views

Custom URI handling: xdg-open and Firefox work, but Chrome doesn't

I'm trying to configure my Linux environment to open obsidian:// URIs using the Obsidian app (see Using Obsidian URI). This is the flow I'm using. I'm doing this on a clean Ubuntu machine to make sure ...
Amir Rachum's user avatar
1 vote
1 answer
2k views

xdg-open from .desktop file (in script)

I am trying to get a shell script to launch a browser. When run standalone, this script successfully opens a browser with xdg-open http://localhost:8080 However, I am trying to make it convenient ...
Real's user avatar
  • 135
1 vote
1 answer
665 views

How do I set priority of which application opens a url schema (rdp://) in kde?

I have several applications installed that handles url schema rdp:// (for example, rdp://[email protected]). These applications are Krdc and Remmina. I want such links to be opened in krdc, but they are ...
Ashark's user avatar
  • 889
1 vote
1 answer
424 views

Open default application for file and wait until it terminates

I tried to use xdg-open but it does not wait until the application terminates. I also tried to get the MIME-type of the file with xdg-mime query filetype fileHere and using xdg-mime query default MIME-...
Cookie04's user avatar
  • 123
1 vote
0 answers
472 views

How to change UnitPath property in systemd? [closed]

I'm experimenting with a non-standard home directory setup making heavy use of $XDG_CONFIG_HOME, $XDG_CACHE_HOME, etc. and most programs have run just fine. Unfortunately, my systemd user service for ...
user avatar
3 votes
2 answers
2k views

Problem with zsh_history file

I am currently trying to clean up my home directory by following this XDG BASE DIRECTORIES website. To do so, i have stored in my ~/.zshenv: # ---- Default editors ---- # export EDITOR="nvim"...
needle's user avatar
  • 153
1 vote
1 answer
393 views

How do I keep stdin open when launching an executable via a Desktop Entry File (i.e. .desktop)?

I have a desktop application that relies on stdin. If I run it in the terminal, it runs great and quits when stdin closes (CTRL+D). I also have a systemd activation socket set up which can launch ...
Stewart's user avatar
  • 13.5k
0 votes
0 answers
703 views

xdg-mime not doing anything

Created an empty file in ~ called test.desktop. Ran xdg-mime default test.desktop inode/directory, which returned success (returned 0). After this, xdg-mime query default inode/directory returned caja-...
Carla is my name's user avatar
6 votes
0 answers
2k views

Portable way to set custom URL scheme handler for all users

I already know how to create a custom URL scheme and set its handler using xdg-utils: xdg-settings set default-url-scheme-handler name handler.desktop However, the command affects only the current ...
trungnt2910's user avatar
3 votes
1 answer
1k views

How to set all youtube links to open in mpv

I would like to set my system to open all links is mpv as default ie. I click link to youtube video in IRC, mumble, discord, signal etc. it opens in mpv. I have read through xdg-open and xdg-mime but ...
Vahvaloac's user avatar
1 vote
0 answers
735 views

xdg-open opens my .desktop file in text viewer or editor instead of launching the executable I want

I tried to create a .desktop file to launch xfreerdp with certain command-line arguments, using https://wiki.archlinux.org/index.php/Desktop_entries as a quick reference. Its file name is something....
muwlgr's user avatar
  • 21
2 votes
0 answers
438 views

xdg-scheme-handler doesn't open script with same terminal that launching it from a desktop menu does

I'm trying to set a x-scheme-handler URI for my python application. This application is launched via a shell script in /usr/bin. I've had a desktop file for a while, and it's worked fine, opening the ...
Tabulate's user avatar
  • 121
1 vote
0 answers
918 views

How do I unset my default xdg browser?

I want to debug a program's behaviour when the user has no default web browser set, but I'm not sure how I'd return to this state after setting one. I know that I can set my default browser via xdg-...
Newbyte's user avatar
  • 1,006
2 votes
1 answer
2k views

Where is the relevant .desktop file?

I can open a Python source file using xdg-open, e.g., $ xdg-open Documents/tmp/paramk.py Waiting for Emacs... $ what happens is that emacsclient is invoked and xdg-open returns when I close the Emacs'...
gboffi's user avatar
  • 1,362
0 votes
1 answer
928 views

Setting DISPLAY=:0 and XAUTHORITY=/home/pi/.Xauthority causes FFmpeg to run poorly

I've setup a webcam viewer that detects when a USB webcam is plugged in with a udev rule, then starts a systemd service that executes a script that starts an FFmpeg/FFplay webcam stream. I noticed ...
SilentNightx's user avatar
2 votes
0 answers
101 views

Is it possible to use unicode character within glob pattern in mime definition file?

I'm issuing the command xdg-mime install nv-custom.xml - using this file: <?xml version="1.0" encoding="UTF-8"?> <mime-info xmlns="http://www.freedesktop.org/...
user418703's user avatar