cvs: peardoc /en/guide/developers/package2 compatible.xml
| From: | Greg Beaver | Date: | Sat, 19 Mar 2005 02:13:35 +0000 |
| Subject: | cvs: peardoc /en/guide/developers/package2 compatible.xml | ||
| Groups: | php.pear.doc | ||
| Request: | Send a blank email to pear-doc+get-5695@lists.php.net to get a copy of this message | ||
cellog Fri Mar 18 21:13:35 2005 EDT
Added files:
/peardoc/en/guide/developers/package2 compatible.xml
Log:
add docs for <compatible>
http://cvs.php.net/co.php/peardoc/en/guide/developers/package2/compatible.xml?r=1.1&p=1
Index: peardoc/en/guide/developers/package2/compatible.xml
+++ peardoc/en/guide/developers/package2/compatible.xml
<!-- $Revision: 1.1 $ -->
<refentry id="guide.developers.package2.compatible">
<refnamediv>
<refname><compatible></refname>
<refpurpose>Alleviating strict versioning with <compatible></refpurpose>
</refnamediv>
<refsect1 id="guide.developers.package2.compatible.intro">
<title>Working with <recommended> dependency versions and
<compatible></title>
<para>
The <compatible> tag is designed to be used with a <package>
dependency that
contains a <recommended> version tag from package pear.example.com/Bar version
1.3.0 like so:
</para>
<para>
<programlisting role="xml">
<![CDATA[
<package>
<name>Foo</name>
<channel>pear.example.com</channel>
<min>1.0.0</min>
<recommended>1.5.2</recommended>
</package>
]]>
</programlisting>
</para>
<para>
The above dependency can be translated into English as follows: "Use the package
pear.example.com/Foo, but only versions 1.0.0 or newer. If pear.example.com/Foo is not
installed, install version 1.5.2. If pear.example.com/Foo is installed and is not version
1.5.2, fail unless --force is specified, or pear.example.com/Foo is compatible with me."
</para>
<para>
That last clause "...or pear.example.com/Foo is compatible with me." is
controlled by the
<compatible> tag. If package Foo version 1.5.3's package.xml has a
<compatible> like so:
</para>
<para>
<programlisting role="xml">
<![CDATA[
<compatible>
<name>Bar</name>
<channel>pear.example.com</channel>
<min>1.2.0</min>
<max>1.3.0</max>
<exclude>1.2.9</exclude>
</compatible>
]]>
</programlisting>
</para>
<para>
This will instruct the installer that pear.example.com/Foo version 1.5.3 is compatible with
pear.example.com/Bar versions 1.2.0 to 1.3.0 inclusive, but is not compatible with 1.2.9.
</para>
<para>
It is very important to note that only <emphasis>existing</emphasis> versions that
have been
tested with the package should be mentioned in the <compatible> tag. Future
versions
of pear.example.com/Bar should simply upgrade the <recommended> tag.
</para>
<para>
<compatible> may contain three versioning tags. The required <min>
and <max>
are used to define the range of tested and compatible versions, and <exclude> is
used to
exclude any versions within the range. In the example above, 1.3.0 and 1.2.0 are the highest and
lowest versions that may be excluded. There can be an unlimited number of
<compatible> tags
inside a package.xml.
</para>
<refsect2>
<title>See also:</title>
<para>
<link
linkend="guide.developers.package2.dependencies.package"><uri></link>
</para>
</refsect2>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
sgml-parent-document:nil
sgml-default-dtd-file:"../../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->