cvs: peardoc /en/guide/migrating postinstall.xml
| From: | Greg Beaver | Date: | Mon, 30 May 2005 04:32:23 +0000 |
| Subject: | cvs: peardoc /en/guide/migrating postinstall.xml | ||
| Groups: | php.pear.doc | ||
| Request: | Send a blank email to pear-doc+get-6123@lists.php.net to get a copy of this message | ||
cellog Mon May 30 00:32:23 2005 EDT
Modified files:
/peardoc/en/guide/migrating postinstall.xml
Log:
start post-install script docs
http://cvs.php.net/diff.php/peardoc/en/guide/migrating/postinstall.xml?r1=1.1&r2=1.2&ty=u
Index: peardoc/en/guide/migrating/postinstall.xml
diff -u peardoc/en/guide/migrating/postinstall.xml:1.1
peardoc/en/guide/migrating/postinstall.xml:1.2
--- peardoc/en/guide/migrating/postinstall.xml:1.1 Sat Mar 26 00:58:19 2005
+++ peardoc/en/guide/migrating/postinstall.xml Mon May 30 00:32:23 2005
@@ -1,21 +1,63 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
-<!-- $Revision: 1.1 $ -->
- <chapter id="guide.migrating.postinstall">
- <chapterinfo>
- <author>
- <firstname>Gregory</firstname>
- <surname>Beaver</surname>
- </author>
- <date>$Date: 2005/03/26 05:58:19 $</date>
- </chapterinfo>
- <title>Post-installation Scripts</title>
-
- <warning>
- <title>Incomplete documentation</title>
- <para>Documentation is not yet complete</para>
- </warning>
+<!-- $Revision: 1.2 $ -->
+<chapter id="guide.migrating.postinstall">
+ <chapterinfo>
+ <author>
+ <firstname>Gregory</firstname>
+ <surname>Beaver</surname>
+ </author>
+ <date>$Date: 2005/05/30 04:32:23 $</date>
+ </chapterinfo>
+ <title>Post-installation Scripts</title>
- </chapter>
+ <warning>
+ <title>Incomplete documentation</title>
+ <para>Documentation is not yet complete</para>
+ </warning>
+
+ <simpara>
+ The XML format for defining a post-install script in package.xml is documented
+ <link
linkend="guide.developers.package2.tasks.postinstallscript">here</link>. This
+ document describes the required elements for the PHP post-install script itself.
+ </simpara>
+
+ <sect1 id="guide.migrating.postinstall.naming">
+ <title>Naming requirements for a post-install script PHP file</title>
+ <titleabbrev>Naming the post-install script</titleabbrev>
+ <para>
+ Post-install script files can be named anything one desires, but the class within
+ the file must be the same name as the file with all path separators replaced by
+ underscores. In other words, this postinstall script:
+ </para>
+ <para>
+ <filename>Path/To/Script.php</filename>
+ </para>
+ <para>
+ Must contain a class named <classname>Path_To_Script</classname>. Due to
+ casing differences between operating systems, it is recommended to always use
+ lowercased file names.
+ </para>
+ </sect1>
+
+ <sect1 id="guide.migrating.postinstall.structure">
+ <title>Structure of a post-install script</title>
+ <titleabbrev>Post-install script structure</titleabbrev>
+ <para>
+ The post-install script class must contain two methods, one named
<function>init</function>,
+ and the other named <function>run</function>. The
<function>init</function> method is called
+ at the same time as all other post-install scripts. The <function>run</function>
method is
+ called at the conclusion of each parameter group in order to process the user's responses
+ to queries.
+ </para>
+
+ <sect2>
+ <title>The <function>run</function> method</title>
+ <para>
+ Unfinished documentation
+ </para>
+ </sect2>
+ </sect1>
+</chapter>
<!-- Keep this comment at the end of the file
Local variables: