Frage

I'm rebuilding my xampp and CI environment (on win7) from scratch but am having trouble running phpdoc through phing. In particular, Phing is looking to phpdocumentor.ini in a place that doesn't exist (and never has).

Phing and PhpDocumentor have both been installed through Pear, paths setup seems fine, and have these versions:

php version 5.4.7
pear version 1.9.4
phpdoc version 2.0.1
phing version 2.6.1     

Relevant paths on the system are:

H:\xampp\php;
H:\xampp\php\pear;

On my sample project:

I can run phpdoc without a hitch, for example: phpdoc -d apps -t docs runs fine.

Here's my phpdoc task, which has worked well in the past:

<phpdoc title=Docs" destdir="${docsdir}" sourcecode="false" output="HTML:frames:earthli">
    <fileset dir="./apps">
        <include name="**/*.php" />
    </fileset>
    <projdocfileset dir=".">
        <include name="README" />
        <include name="INSTALL" />
        <include name="CHANGELOG" />
    </projdocfileset>
</phpdoc>

When I run Phing, phpdoc fails with the following notice:

Parsing configuration file phpDocumentor.ini...
   (found in C:\php\pear\data/PhpDocumentor/)...
ERROR: cannot open phpDocumentor.ini in directory
-Is phpdoc in either the path or include_path in your php.ini file?

There is no c:\php... directory, and never has been, so I don't know where this has come from.

I can only get this working if I create the whole PHPDocumentor structure Phing anticipates on C: but I'd ideally like to get the ini file's anticipated location changed so I have everything on the one drive.

Is there any way I can inform Phing of the true location of my phpdocumentor.ini?

I've not found this specific problem listed on SO, but am hopeful someone else has seen and rectified this. The Phing site docs/forum/trac don't list any recent reports of this problem.

Thanks all

War es hilfreich?

Lösung

It looks like you're trying to use phpDocumentor 2.x and seeing some behavior from what looks like phpDocumentor 1.x. Perhaps there is some 1.x code that came with the XAMPP source that is lingering and affecting your ability to run 2.x cleanly.

In considering the Phing angle, in glancing at the Phing manual, it looks like the correct Phing task to use for phpDocumentor 2.x is the DocBlox task [1] rather than the old PhpDoc task.

[1] -- http://www.phing.info/docs/guide/stable/apcs52.html.

Andere Tipps

Downloading the latest zip archive release of XAMPP for Windows I see that the file:

\xampp\php\pear\PhpDocumentor\phpDocumentor\Setup.inc.php

the function parseIni() refers directly to the aforementioned path:

enter code herephpDocumentor_out(" (found in " . 'C:\php\pear\data/PhpDocumentor' . PATH_DELIMITER . ")...\n");

So its more likely to be a XAMPP problem than any of the components I've been upgrading or force-reinstalling.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top