glib/docs/reference/gio/gresource.xml
2012-01-23 00:26:05 -05:00

117 lines
3.4 KiB
XML

<refentry id="gresource-tool" lang="en">
<refmeta>
<refentrytitle>gresource</refentrytitle>
<manvolnum>1</manvolnum>
<refmiscinfo class="manual">User Commands</refmiscinfo>
</refmeta>
<refnamediv>
<refname>gresource</refname>
<refpurpose>GResource tool</refpurpose>
</refnamediv>
<refsynopsisdiv>
<cmdsynopsis>
<command>gresource</command>
<arg choice="opt">--section <replaceable>SECTION</replaceable></arg>
<arg choice="plain">list</arg>
<arg choice="plain"><replaceable>FILE</replaceable></arg>
<arg choice="opt"><replaceable>PATH</replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<command>gresource</command>
<arg choice="opt">--section SECTION</arg>
<arg choice="plain">details</arg>
<arg choice="plain"><replaceable>FILE</replaceable></arg>
<arg choice="opt"><replaceable>PATH</replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<command>gresource</command>
<arg choice="opt">--section SECTION</arg>
<arg choice="plain">extract</arg>
<arg choice="plain"><replaceable>FILE</replaceable></arg>
<arg choice="plain"><replaceable>PATH</replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<command>gresource</command>
<arg choice="plain">sections</arg>
<arg choice="plain"><replaceable>FILE</replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<command>gresource</command>
<arg choice="plain">help</arg>
<arg choice="opt"><replaceable>COMMAND</replaceable></arg>
</cmdsynopsis>
</refsynopsisdiv>
<refsect1><title>Description</title>
<para><command>gresource</command> offers a simple commandline
interface to <link linkend="GResource"><type>GResource</type></link>.
It lets you list and extract resources that have been compiled
into a resource file or included in an elf file (a binary or a
shared library).
</para>
<para>
The file to operate on is specified by the <replaceable>FILE</replaceable>
argument.
</para>
<para>
If an elf file includes multiple sections with resources, it is
possible to select which one to operate on with the
<arg choice="plain">--section</arg> option. Use the
<arg choice="plain">sections</arg> command to find available sections.
</para>
<refsect2><title>Commands</title>
<variablelist>
<varlistentry>
<term><option>list</option></term>
<listitem><para>
Lists resources. If <replaceable>SECTION</replaceable> is given, only
list resourcs in this section. If <replaceable>PATH</replaceable> is
given, only list matching resources.
</para></listitem>
</varlistentry>
<varlistentry>
<term><option>details</option></term>
<listitem><para>
Lists resources with details. If <replaceable>SECTION</replaceable>
is given, only list resources in this section. If
<replaceable>PATH</replaceable> is given, only list matching resources.
Details include the section, size and compression of each resource.
</para></listitem>
</varlistentry>
<varlistentry>
<term><option>extract</option></term>
<listitem><para>
Extracts the resource named by <replaceable>PATH</replaceable> to stdout.
Note that resources may contain binary data.
</para></listitem>
</varlistentry>
<varlistentry>
<term><option>sections</option></term>
<listitem><para>
Lists sections containing resources. This is only interesting if
<replaceable>FILE</replaceable> is an elf file.
</para></listitem>
</varlistentry>
<varlistentry>
<term><option>help</option></term>
<listitem><para>
Prints help and exits.
</para></listitem>
</varlistentry>
</variablelist>
</refsect2>
</refsect1>
</refentry>