Issue
Im trying to simplify my package.xml
file, because it contains many of this
<phprelease>
<filelist>
<install as="path/to/my/Class.php" name="classes/path/to/my/Class.php" />
<!-- Many more of this -->
</filelist>
</phprelease>
According the Manual, it should be possible, to strip relative paths by using the baseinstalldir
-attribute, but its either (a kind of) ignored, or leads to curious pathnames. For example
<dir name="/">
<dir name="classes">
<file baseinstalldir="/path/to/my" name="path/to/my/Class.php" role="php" />
</dir>
</dir>
installs the file into path/to/my/classes/path/to/my/Class.php
, that is obvious crap.
Does anyone knows a solution to strip one folder from the path, that does not require a big bunch of install-as
-elements?
Update:
It seems, that the pear packager rewrites package.xml
, before it puts it into the package. One of the steps it performs is, that it flattens the contents
-section.
<dir name="/">
<dir name="classes">
<file baseinstalldir="/path/to/my" name="path/to/my/Class.php" role="php" />
</dir>
</dir>
becomes
<dir name="/">
<file baseinstalldir="/path/to/my" name="classses/path/to/my/Class.php" role="php" />
</dir>
The installer resolve this to path/to/my/classes/path/to/my/Class.php
of course...
Solution
PEAR does not support what you want (that is, package.xml
v2.0).
Pyrus supports package.xml
v2.1 which behaves exactly as you expect it.
Answered By - cweiske Answer Checked By - Mildred Charles (PHPFixing Admin)
0 Comments:
Post a Comment
Note: Only a member of this blog may post a comment.