Ask Your Question

Desktop Files not found

asked 2016-05-03 17:04:36 -0600

zelphir gravatar image

I am running a Fedora 22 with Gnome 3. When I place .desktop files like the one here into my ~/.local/share/applications directory, they still don't show up when I type parts of the name of the application in the dash.

Is there anything special one needs to do to enable those desktop files?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2016-05-03 20:23:31 -0600

florian gravatar image

updated 2016-05-04 14:20:03 -0600

Make sure those manually created .desktop files begin like this

#!/usr/bin/env xdg-open
[Desktop Entry]

EDIT: You can also use destop-file-validate <your_desktop_file> to check and validate your file. (The tool is part of the package desktop-file-utils.)

edit flag offensive delete link more


It was the #!/usr/bin/env xdg-open missing and the fact that there cannot be an empty line between #!/usr/bin/env xdg-open and the [Desktop Entry] line. Thanks!

zelphir gravatar imagezelphir ( 2016-05-04 06:45:29 -0600 )edit

some more background info: https://specifications.freedesktop.or...

gobigobi66 gravatar imagegobigobi66 ( 2016-05-04 13:32:41 -0600 )edit

I can't make it work for my program DS9. I have the following desktop file:

$ cat ds9.desktop 
[Desktop Entry]
Comment=Astronomical Data Visualization Application


Even with the line you mention it doesn't work. And I didn't find anything about that line in the documentation of desktop files. Any thoughts?

skytux gravatar imageskytux ( 2016-05-05 07:54:59 -0600 )edit

@skytux : true, the documentation doesn't mention that one line. My personal experience was that at some point my manually created .desktop files were not working, and after some online research I found the solution to my problem: #!/usr/bin/env xdg-open Unfortunately, I can't find the same source right now but I think it was in

Doing a quick search now, I found this, which talks a bit about the hashpling.

Really interesting that the freedesktop's documenation doesn't mention it.

florian gravatar imageflorian ( 2016-05-05 21:29:10 -0600 )edit

Thanks @florian! I'm going to take a look at that link.

skytux gravatar imageskytux ( 2016-05-06 06:49:08 -0600 )edit

Question Tools

1 follower


Asked: 2016-05-03 17:04:36 -0600

Seen: 374 times

Last updated: May 04 '16