Desktop Shortcuts

From GnuCash
Revision as of 19:10, 13 January 2014 by Twt (talk | contribs) (How to create GnuCash desktop files for multiple versions or files)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Make a desktop file, set permissions, and move to the correct location for your environment.

1. Create a plain text file called gnucash-xyz.desktop containing the following:

[Desktop Entry]
Name=GnuCash 2.6
Terminal=false
Icon=/usr/share/pixmaps/gnucash-icon-256x256.png
Type=Application
Encoding=UTF-8
Categories=Office;Finance;
Exec=/usr/bin/gnucash /path/to/myfile
Comment=Manage your finances, accounts, and investments

2. Set the permissions and copy the file to a known place.

$ chmod 644 gnucash-xyz.desktop $ cp gnucash-xyz.desktop /usr/share/applications/

3. Create a link from the executable file to the name used in the desktop file if if you are using / testing multiple versions of GnuCash.

You might want separate icons for stable, distro, and latest, and easily relink to a new version, and if something goes really bad, relink to the old version without downtime. Also you might find different configurations install to different locations, so good to check this matches your system.

$ ln -s /usr/local/bin/gnucash /usr/bin/

You might copy the svg file or the png file for your bitmap:

$ cp /usr/local/share/gnucash/pixmaps/gnucash-icon-256x256.png /usr/share/pixmaps/

For more information on desktop shortcuts, see [official desktop entry specification].

[Thanks to Bob Brush on the GnuCash Users email list for the initial content of this page.]