264 lines
8.5 KiB
HTML
264 lines
8.5 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of DESKTOP-FILE-INSTALL</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>DESKTOP-FILE-INSTALL</H1>
|
|
Section: User Commands (1)<BR>Updated: FREEDESKTOP.ORG<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NAME</H2>
|
|
|
|
desktop-file-install, desktop-file-edit - Installation and edition of desktop files
|
|
<A NAME="lbAC"> </A>
|
|
<H2>SYNOPSIS</H2>
|
|
|
|
<B>desktop-file-install [--dir=DIR] [-m MODE|--mode=MODE]</B>
|
|
|
|
<B>[--vendor=VENDOR] [--delete-original]</B>
|
|
|
|
<B>[--rebuild-mime-info-cache]</B>
|
|
|
|
<B>[EDITOPTION]... FILE...</B>
|
|
|
|
<P>
|
|
|
|
<B>desktop-file-edit [EDITOPTION]... FILE</B>
|
|
|
|
<A NAME="lbAD"> </A>
|
|
<H2>DESCRIPTION</H2>
|
|
|
|
The <I>desktop-file-install</I> program is a tool to install, and
|
|
optionally edit, desktop files. The <I>desktop-file-edit</I> program is a
|
|
tool to edit a desktop file. They are mostly useful for developers and
|
|
packagers.
|
|
<P>
|
|
|
|
Various options are available to edit the desktop files. The edit
|
|
options can be specified more than once and will be processed in the
|
|
same order as the options passed to the program.
|
|
<P>
|
|
|
|
<I>desktop-file-install</I> and <I>desktop-file-edit</I> will always try
|
|
to validate the resulting desktop file. A failure to validate might lead
|
|
to the abortion of the installation of the desktop files.
|
|
<P>
|
|
|
|
The list of registered categories and desktop environments is defined in
|
|
the Menu specification:
|
|
<I><A HREF="http://freedesktop.org/wiki/Specifications/menu-spec">http://freedesktop.org/wiki/Specifications/menu-spec</A></I>.
|
|
<A NAME="lbAE"> </A>
|
|
<H2>OPTIONS</H2>
|
|
|
|
The following options are supported:
|
|
<DL COMPACT>
|
|
<DT id="1"><I>--dir=DIR</I>
|
|
|
|
<DD>
|
|
Install desktop files to the <I>DIR</I> directory.
|
|
<DT id="2"><I>-m, --mode=MODE</I>
|
|
|
|
<DD>
|
|
Set the permissions of the destination files to <I>MODE</I>.
|
|
<DT id="3"><I>--vendor=VENDOR</I>
|
|
|
|
<DD>
|
|
Add a vendor prefix to the desktop files. If a file already has this
|
|
prefix, nothing happens; else, the file will be named
|
|
<I>VENDOR</I>-<I>FILE</I>. For example: if <I>VENDOR</I> is
|
|
<B>freedesktop.org</B> and <I>FILE</I> is <B>specification.desktop</B>, the
|
|
result file will be <B>freedesktop.org-specification.desktop</B>.
|
|
<DT id="4"><I>--delete-original</I>
|
|
|
|
<DD>
|
|
Delete the source desktop files, leaving only the target files.
|
|
Effectively "renames" the desktop files.
|
|
<DT id="5"><I>--rebuild-mime-info-cache</I>
|
|
|
|
<DD>
|
|
Rebuild the MIME types application database after installing the desktop
|
|
files. See <I><A HREF="/cgi-bin/man/man2html?1+update-desktop-database">update-desktop-database</A>(1)</I> for information about this
|
|
database.
|
|
</DL>
|
|
<P>
|
|
|
|
<A NAME="lbAF"> </A>
|
|
<H2>EDIT OPTIONS</H2>
|
|
|
|
The following edit options are supported:
|
|
<DL COMPACT>
|
|
<DT id="6"><I>--set-key=KEY</I>
|
|
|
|
<DD>
|
|
Set the KEY key to the value passed to the next <I>--set-value</I>
|
|
option. A matching <I>--set-value</I> option is mandatory.
|
|
<DT id="7"><I>--set-value=VALUE</I>
|
|
|
|
<DD>
|
|
Set the key specified with the previous <I>--set-key</I> option to VALUE.
|
|
A matching <I>--set-key</I> option is mandatory.
|
|
<DT id="8"><I>--set-name=NAME</I>
|
|
|
|
<DD>
|
|
Set the name (key <B>Name</B>) to NAME. If a name was already set, it
|
|
will be overridden. Localizations of the old name will be removed.
|
|
<DT id="9"><I>--copy-name-to-generic-name</I>
|
|
|
|
<DD>
|
|
Copy the value of the <B>Name</B> key to the <B>GenericName</B> key. Note
|
|
that a desktop file requires a <B>Name</B> key to be valid, so this
|
|
option will always have an effect.
|
|
<DT id="10"><I>--set-generic-name=GENERIC-NAME</I>
|
|
|
|
<DD>
|
|
Set the generic name (key <B>GenericName</B>) to GENERIC-NAME. If a
|
|
generic name was already set, it will be overridden. Localizations of
|
|
the old generic name will be removed.
|
|
<DT id="11"><I>--copy-generic-name-to-name</I>
|
|
|
|
<DD>
|
|
Copy the value of the <B>GenericName</B> key to the <B>Name</B> key, if
|
|
the <B>GenericName</B> key is present.
|
|
<DT id="12"><I>--set-comment=COMMENT</I>
|
|
|
|
<DD>
|
|
Set the comment (key <B>Comment</B>) to COMMENT. If a comment was already
|
|
set, it will be overridden. Localizations of the old comment will be
|
|
removed.
|
|
<DT id="13"><I>--set-icon=ICON</I>
|
|
|
|
<DD>
|
|
Set the icon (key <B>Icon</B>) to ICON. If an icon was already set, it
|
|
will be overridden. Localizations of the old icon will be removed.
|
|
<DT id="14"><I>--add-category=CATEGORY</I>
|
|
|
|
<DD>
|
|
Add <I>CATEGORY</I> to the list of categories (key <B>Categories</B>). If
|
|
<I>CATEGORY</I> was already present in the list, this operation is a
|
|
no-op. A non-registered category should be prefixed with <B>X-</B>.
|
|
<DT id="15"><I>--remove-category=CATEGORY</I>
|
|
|
|
<DD>
|
|
Remove <I>CATEGORY</I> from the list of categories (key
|
|
<B>Categories</B>). If <I>CATEGORY</I> was not present in the list, this
|
|
operation is a no-op.
|
|
<DT id="16"><I>--add-mime-type=MIME-TYPE</I>
|
|
|
|
<DD>
|
|
Add <I>MIME-TYPE</I> to the list of MIME types (key <B>MimeType</B>). If
|
|
<I>MIME-TYPE</I> was already present in the list, this operation is a
|
|
no-op.
|
|
<DT id="17"><I>--remove-mime-type=MIME-TYPE</I>
|
|
|
|
<DD>
|
|
Remove <I>MIME-TYPE</I> from the list of MIME types (key <B>MimeType</B>).
|
|
If <I>MIME-TYPE</I> was not present in the list, this operation is a
|
|
no-op.
|
|
<DT id="18"><I>--add-only-show-in=ENVIRONMENT</I>
|
|
|
|
<DD>
|
|
Add <I>ENVIRONMENT</I> to the list of desktop environments where the
|
|
desktop files should be displayed (key <B>OnlyShowIn</B>). If
|
|
<I>ENVIRONMENT</I> was already present in the list, this operation is a
|
|
no-op. A non-registered desktop environment should be prefixed with
|
|
<B>X-</B>. Note that an empty <B>OnlyShowIn</B> key in a desktop file
|
|
means that the desktop file will be displayed in all environments.
|
|
<DT id="19"><I>--remove-only-show-in=ENVIRONMENT</I>
|
|
|
|
<DD>
|
|
Remove <I>ENVIRONMENT</I> from the list of desktop environments where the
|
|
desktop files should be displayed (key <B>OnlyShowIn</B>). If
|
|
<I>ENVIRONMENT</I> was not present in the list, this operation is a
|
|
no-op.
|
|
<DT id="20"><I>--add-not-show-in=ENVIRONMENT</I>
|
|
|
|
<DD>
|
|
Add <I>ENVIRONMENT</I> to the list of desktop environments where the
|
|
desktop files should not be displayed (key <B>NotShowIn</B>). If
|
|
<I>ENVIRONMENT</I> was already present in the list, this operation is a
|
|
no-op. A non-registered desktop environment should be prefixed with
|
|
<B>X-</B>. Note that an empty <B>NotShowIn</B> key in a desktop file
|
|
means that the desktop file will be displayed in all environments.
|
|
<DT id="21"><I>--remove-not-show-in=ENVIRONMENT</I>
|
|
|
|
<DD>
|
|
Remove <I>ENVIRONMENT</I> from the list of desktop environments where the
|
|
desktop files should not be displayed (key <B>NotShowIn</B>). If
|
|
<I>ENVIRONMENT</I> was not present in the list, this operation is a
|
|
no-op.
|
|
<DT id="22"><I>--remove-key=KEY</I>
|
|
|
|
<DD>
|
|
Remove the <I>KEY</I> key from the desktop files, if present.
|
|
</DL>
|
|
<A NAME="lbAG"> </A>
|
|
<H2>ENVIRONMENT</H2>
|
|
|
|
Some environment variables change the behavior of
|
|
<I>desktop-file-install</I>:
|
|
<P>
|
|
|
|
<B>DESKTOP_FILE_VENDOR</B>
|
|
|
|
<DL COMPACT>
|
|
<DT id="23"><DD>
|
|
This variable can be used as an alternative to the <I>--vendor</I>
|
|
option. If the <I>--vendor</I> option is used, this environment variable
|
|
will be ignored.
|
|
</DL>
|
|
<P>
|
|
|
|
<B>DESKTOP_FILE_INSTALL_DIR</B>
|
|
|
|
<DL COMPACT>
|
|
<DT id="24"><DD>
|
|
This variable can be used as an alternative to the <I>--dir</I>
|
|
option. If the <I>--dir</I> option is used, this environment variable
|
|
will be ignored.
|
|
</DL>
|
|
<P>
|
|
|
|
<B>RPM_BUILD_ROOT</B>
|
|
|
|
<DL COMPACT>
|
|
<DT id="25"><DD>
|
|
This variable is set when building RPM packages. If the <I>--dir</I>
|
|
option and the <B>DESKTOP_FILE_INSTALL_DIR</B> environment variable are
|
|
not used, it will automatically be prepended to the default install
|
|
directory to install the desktop files appropriately when building
|
|
packages.
|
|
</DL>
|
|
<A NAME="lbAH"> </A>
|
|
<H2>BUGS</H2>
|
|
|
|
If you find bugs in the <I>desktop-file-install</I> program, please report
|
|
these on <A HREF="https://bugs.freedesktop.org.">https://bugs.freedesktop.org.</A>
|
|
<A NAME="lbAI"> </A>
|
|
<H2>SEE ALSO</H2>
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?1+desktop-file-validate">desktop-file-validate</A>(1)</B>
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?1+update-desktop-database">update-desktop-database</A>(1)</B>
|
|
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="26"><A HREF="#lbAB">NAME</A><DD>
|
|
<DT id="27"><A HREF="#lbAC">SYNOPSIS</A><DD>
|
|
<DT id="28"><A HREF="#lbAD">DESCRIPTION</A><DD>
|
|
<DT id="29"><A HREF="#lbAE">OPTIONS</A><DD>
|
|
<DT id="30"><A HREF="#lbAF">EDIT OPTIONS</A><DD>
|
|
<DT id="31"><A HREF="#lbAG">ENVIRONMENT</A><DD>
|
|
<DT id="32"><A HREF="#lbAH">BUGS</A><DD>
|
|
<DT id="33"><A HREF="#lbAI">SEE ALSO</A><DD>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:05:10 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|