Questions tagged [xdgutils]

The xdg-utils package is a set of simple scripts that provide basic desktop integration functions for any Free Desktop, such as Linux. They are intended to provide a set of defacto standards.

This version of xdg-utils contains the following commands:

  • xdg-desktop-menu: command line tool for (un)installing desktop menu items
  • xdg-desktop-icon: command line tool for (un)installing icons to the desktop
  • xdg-mime: command line tool for querying information about file type handling and adding descriptions for new file types
  • xdg-icon-resource: command line tool for (un)installing icon resources
  • xdg-open: opens a file or URL in the user's preferred application
  • xdg-email: command line tool for sending mail using the user's preferred e-mail composer
  • xdg-screensaver: command line tool for controlling the screensaver
68 questions
45
votes
4 answers

Equivalents of XDG_CONFIG_HOME and XDG_DATA_HOME on Mac OS X?

I am planning to develop a cross-platform script. On Linux and other operating systems, it will store configuration in XDG_CONFIG_HOME and data files (specifically, downloaded plugins) in XDG_DATA_HOME. On Windows, it will use APPDATA for both…
LeafStorm
  • 3,057
  • 4
  • 24
  • 28
12
votes
3 answers

xdg-open : no method available even after installing xdg-utils

I am using generator-angular-fullstack. On my local machine its working fine, I run grunt serve it starts server but in VPS it's failing Warning: Command failed: xdg-open: no method available for opening 'http://localhost:9000' and I have…
Neo
  • 4,550
  • 6
  • 34
  • 51
7
votes
4 answers

error: XDG_RUNTIME_DIR not set in the environment. Gtk-WARNING **: cannot open display:

I used to open text files with sublime, and for Read-only files, I used to do : sudo sublime. But now just suddenly the sudo sublime command gives the following error : (sublime:3931): Gtk-WARNING **: cannot open display: while sublime command is…
Sahil Arora
  • 875
  • 2
  • 8
  • 27
7
votes
2 answers

Get list of applications for opening a specific file

How can I get a list of applications that are capable to open a specific filetype / MIME-type? I'm searching for a desktop-environment independent solution on Linux. I found the possibilty to get the MIME type for a file.: ~> xdg-mime query filetype…
BuZZ-dEE
  • 6,075
  • 12
  • 66
  • 96
7
votes
2 answers

HTML tag mailto generates wrong address

I am using ubuntu 15.04 and chrome. When i click on any html link with mailto protocol e.g. Click to send me email! It opens my default email application (thunderbird) but populate address field with wrong…
Shahzad Tariq
  • 2,767
  • 1
  • 22
  • 31
7
votes
2 answers

Alter Behavior of xdg-open

I use the command xdg-open quite a lot in my Ubuntu Linux terminal. However, two things irk me: Is it possible to suppress the error messages? Is it possible to get the command to always complete? (That is, not continue running, so that I have…
pyrrhic
  • 1,769
  • 2
  • 15
  • 27
6
votes
3 answers

How to open the user's preferred mail application on Linux?

I wrote a simple native GUI script with python-gtk. Now I want to give the user a button to send an email with an attachment. The script runs on Linux desktops. Is there a way to open the user's preferred mail application and attach a file?
guettli
  • 25,042
  • 81
  • 346
  • 663
5
votes
1 answer

Perl: wait for xdg-open to quit before continuing

I have a Perl script that produces a pdf $pdffile in a temporary directory $tempdir and opens it using xdg-open. The script should then delete the working directory once the user is done looking at the file. Here's the part of the code that I'm…
MTS
  • 268
  • 2
  • 6
5
votes
2 answers

Adding several attachments to thunderbird (from command line)

I try to create a new message with several attachments via command line, but this does not work: thunderbird -compose "attachment='/etc/mtab',attachment='/etc/fstab'" Only the first file gets attached. The second is missing. What is wrong with the…
guettli
  • 25,042
  • 81
  • 346
  • 663
4
votes
1 answer

How do I set the default browser for xdg-open on Centos 7 if xdg-settings has no desktop environment

There are many questions similar to mine (e.g. xdg-open not open default browser or xdgutils - xdg-settings not setting default-web-browser in gentoo, but none of the answers helped in my case. Therefor I ask for my particular situation: On Centos…
halloleo
  • 9,216
  • 13
  • 64
  • 122
4
votes
1 answer

How to fix xdg-open: no method available for opening 'http://localhost:80'

When I press the button [Go To Application] in the XAMPP 7.3.6 Shows me this: xdg-open: no method available for opening 'http://localhost:80' I set the /usr/bin/xdg-open where google-chromium is now chromium. That solved all my problems and bugs…
Kirat
  • 69
  • 1
  • 2
  • 6
4
votes
3 answers

Open file with default application from Vala?

What's the best way to open a file in the default application from Vala? A bit like how xdg-open works.
Peter Uithoven
  • 705
  • 1
  • 6
  • 17
4
votes
1 answer

How do you parse the XDG/gnome/kde menu/desktop item structure in c++?

I would like to parse the menu structure for Gnome Panels (the standard Gnome Desktop application launcher) and it's KDE equivalent using c/c++ function calls. That is, I'd like a list of what the base menu categories and submenu are installed in a…
Joe Soul-bringer
  • 3,294
  • 5
  • 31
  • 37
4
votes
1 answer

Open file in Eclipse through URL handler

In my project, I have a special JSP which displays the exception stacktrace in case of Exceptions. Is there a way to use an URL handler or something else which would have Eclipse open a file? Maybe with xdg-open? I use Eclipse 4.3 on Kubuntu Linux.
yglodt
  • 13,807
  • 14
  • 91
  • 127
4
votes
2 answers

Using XDG directory specification on Java application

I'm trying to follow XDG directory specification on my Java application. I have already used it for application data: protected String getDefaultDataDir() { String rootPath = System.getenv("XDG_DATA_HOME"); if(rootPath == null) { …
Flamma
  • 258
  • 4
  • 15
1
2 3 4 5