pyrus / Pyrus

The next generation of the PEAR installer.
http://pear2.php.net/
Other
70 stars 18 forks source link

Package Name not same when package is created #94

Closed harikt closed 11 years ago

harikt commented 12 years ago

The package name in xml is Aura.Autoload , but the package created is Aura.0.0beta2.tgz , which misses the second value after the dot . Though the output says its creating Aura.Autoload-1.0.0.beta2.tgz , see it misses Autoload-1

hari@hari-Vostro1510:/media/Linux/auraphp/system/package/Aura.Autoload$ pyrus package
Using PEAR installation found at /media/Linux/pyrus
Creating Aura.Autoload-1.0.0beta2.tgz
done
hari@hari-Vostro1510:/media/Linux/auraphp/system/package/Aura.Autoload$ ls
Aura.0.0beta2.tgz  composer.json  config  docs  LICENSE  meta  package.ini  package.xml  README.md  scripts  src  src.php  tests

The package.xml file is

<?xml version="1.0"?>
<package xmlns="http://pear.php.net/dtd/package-2.0" xmlns:tasks="http://pear.php.net/dtd/tasks-1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" packagerversion="1.4.10" version="2.0" xsi:schemaLocation="http://pear.php.net/dtd/tasks-1.0        http://pear.php.net/dtd/tasks-1.0.xsd        http://pear.php.net/dtd/package-2.0        http://pear.php.net/dtd/package-2.0.xsd">
  <name>Aura.Autoload</name>
  <channel>pear.php.net</channel>
  <summary>The Aura Autoload package provides a PSR-0 compliant SPL autoloader implementation for PHP. It also matches the proposed SplClassLoader interface.</summary>
  <description>The Aura Autoload package provides a PSR-0 compliant SPL autoloader implementation for PHP. It also matches the proposed SplClassLoader interface.</description>
  <lead>
    <name>Paul M Jones</name>
    <user/>
    <email>hismailid@gmail.com</email>
    <active>yes</active>
  </lead>
  <date>2012-02-19</date>
  <time>08:34:32</time>
  <version>
    <release>1.0.0beta2</release>
    <api>1.0.0beta2</api>
  </version>
  <stability>
    <release>alpha</release>
    <api>alpha</api>
  </stability>
  <license>PHP</license>
  <notes>-</notes>
  <contents>
    <dir name="/">
      <file name="tests/bootstrap.php" role="test" md5sum="241d75b80313c4d6216b43971e2ea0d5"/>
      <file name="tests/phpunit.xml" role="test" md5sum="b5189493c7f1668f6dbe6527ca4b720c"/>
      <file name="tests/Aura/Autoload/MockAutoloadUndeclared2.php" role="test" md5sum="8970d29dd5eb3775bff37b92132ad5e6"/>
      <file name="tests/Aura/Autoload/MockAutoloadChild.php" role="test" md5sum="ceac549781364a4443670a1912b94d68"/>
      <file name="tests/Aura/Autoload/Bar/MockAutoloadRouterClass.php" role="test" md5sum="a8a26d558f6948ae4acde1187a8cb98d"/>
      <file name="tests/Aura/Autoload/LoaderTest.php" role="test" md5sum="1ab244270421f51a5a6b7eee825c9949"/>
      <file name="tests/Aura/Autoload/Foo/MockAutoloadCliClass.php" role="test" md5sum="6e74d1c0a97785659dc59e4ecaafe6c0"/>
      <file name="tests/Aura/Autoload/MockAutoloadClass.php" role="test" md5sum="f9790583d1a137914af6693a5940de7e"/>
      <file name="tests/Aura/Autoload/MockAutoloadAlready.php" role="test" md5sum="d73a302acbbfd3ed2962fac1f76fd704"/>
      <file name="tests/Aura/Autoload/MockAutoloadUndeclared1.php" role="test" md5sum="799843d752f99e3fb88860206ff10aa7"/>
      <file name="src/Aura/Autoload/Exception/NotReadable.php" role="php" md5sum="d9425a00148745a628085ca352577924"/>
      <file name="src/Aura/Autoload/Exception/AlreadyLoaded.php" role="php" md5sum="7e3cab95b603b3c2af2c0fcc9759aa48"/>
      <file name="src/Aura/Autoload/Exception/NotDeclared.php" role="php" md5sum="67fd5557fc92e9d2ca2fbbe8f91b15a5"/>
      <file name="src/Aura/Autoload/Loader.php" role="php" md5sum="7cd2ed2aefd7eade8be1e9f23cb90bfd"/>
      <file name="src/Aura/Autoload/Exception.php" role="php" md5sum="eb49f0026d17f9266c6d255329b881a4"/>
    </dir>
  </contents>
  <dependencies>
    <required>
      <php>
        <min>5.4</min>
      </php>
      <pearinstaller>
        <min>1.4</min>
      </pearinstaller>
    </required>
  </dependencies>
  <phprelease>
    <filelist>
      <install name="tests/bootstrap.php" as="bootstrap.php"/>
      <install name="tests/phpunit.xml" as="phpunit.xml"/>
      <install name="tests/Aura/Autoload/MockAutoloadUndeclared2.php" as="Aura/Autoload/MockAutoloadUndeclared2.php"/>
      <install name="tests/Aura/Autoload/MockAutoloadChild.php" as="Aura/Autoload/MockAutoloadChild.php"/>
      <install name="tests/Aura/Autoload/Bar/MockAutoloadRouterClass.php" as="Aura/Autoload/Bar/MockAutoloadRouterClass.php"/>
      <install name="tests/Aura/Autoload/LoaderTest.php" as="Aura/Autoload/LoaderTest.php"/>
      <install name="tests/Aura/Autoload/Foo/MockAutoloadCliClass.php" as="Aura/Autoload/Foo/MockAutoloadCliClass.php"/>
      <install name="tests/Aura/Autoload/MockAutoloadClass.php" as="Aura/Autoload/MockAutoloadClass.php"/>
      <install name="tests/Aura/Autoload/MockAutoloadAlready.php" as="Aura/Autoload/MockAutoloadAlready.php"/>
      <install name="tests/Aura/Autoload/MockAutoloadUndeclared1.php" as="Aura/Autoload/MockAutoloadUndeclared1.php"/>
      <install name="src/Aura/Autoload/Exception/NotReadable.php" as="Aura/Autoload/Exception/NotReadable.php"/>
      <install name="src/Aura/Autoload/Exception/AlreadyLoaded.php" as="Aura/Autoload/Exception/AlreadyLoaded.php"/>
      <install name="src/Aura/Autoload/Exception/NotDeclared.php" as="Aura/Autoload/Exception/NotDeclared.php"/>
      <install name="src/Aura/Autoload/Loader.php" as="Aura/Autoload/Loader.php"/>
      <install name="src/Aura/Autoload/Exception.php" as="Aura/Autoload/Exception.php"/>
    </filelist>
  </phprelease>
</package>

package.xml is created via Onion as I feel its an easy way https://github.com/c9s/Onion/

package.ini of onion is

[package]
name = Aura.Autoload
desc = The Aura Autoload package provides a PSR-0 compliant SPL autoloader implementation for PHP. It also matches the proposed SplClassLoader interface.
version = 1.0.0beta2
channel = pear.php.net
author = Paul M Jones <hismailid@gmail.com>

[require]
php = 5.4
pearinstaller = 1.4

[roles]
docs = doc

Create the package.xml

$ onion build

Checking directory structure...
    * doc/ directory not found.
Configuring package.ini
Reading config file: package.ini
Configuring dependencies...
Writing package.xml...
Building contents section...
Building dependencies section...
Building phprelease section...
package.xml is generated. you can now build your PEAR package with:

PEAR:

    $ pear -q package

Pyrus:

    $ pyrus.phar package
Done.