You are not logged in.

#1 2009-06-02 10:08:57

fifafrazer
Member
Registered: 2008-02-18
Posts: 81

How can I make dmenu_run read .desktop files?

I'm using dmenu as an alternative for gnome-do, and I'm running it with 'dmenu_run'.
But not all programs are in the PATH, so I would like dmenu to read my .desktop files
too, like the menus in Xfce, GNOME etc.

Offline

#2 2009-06-02 13:27:49

Mr.Elendig
#archlinux@freenode channel op
From: The intertubes
Registered: 2004-11-07
Posts: 4,092

Re: How can I make dmenu_run read .desktop files?

Write a script that parses the .desktop files, and pipes the choices to dmenu?

If you are lucky, someone have already done this.


Evil #archlinux@libera.chat channel op and general support dude.
. files on github, Screenshots, Random pics and the rest

Offline

#3 2009-06-02 21:10:30

fifafrazer
Member
Registered: 2008-02-18
Posts: 81

Re: How can I make dmenu_run read .desktop files?

That will be my project for the weekend.
The main concern to deal with is that you only want the names and not the paths in the menu, but you have to connect them afterwards.

Offline

#4 2009-06-02 21:32:32

brisbin33
Member
From: boston, ma
Registered: 2008-07-24
Posts: 1,796
Website

Re: How can I make dmenu_run read .desktop files?

as long as $PATH is set, you shouldn't need to reconnect them (i think).  if you send the list of apps through | awk -F '/' '{print $NF}' | that'll strip the path

/edit: added the "(i think)" part wink

Last edited by brisbin33 (2009-06-02 21:33:06)

Offline

Board footer

Powered by FluxBB