Installing manually PHPDocumentor on Mac

code-documentation, documentation, documentation-generation, phpdoc

Solution

Did you try :

curl -s http://getcomposer.org/installer | php

php composer install

on phpdocumentor2 directory (you should find composer.json)

Composer is a dependency manager for php. So it will populate phpdocumentor projet with external/vendor dependencies

Problem

After trying to install PHPDocumentor with PEAR install with no success, i tried it manually as is detailed on the official website: http://www.phpdoc.org/docs/latest/for-users/installation.html I downloaded the files and i make an alias on /usr/bin/ but when i try to execute phpdoc.php via terminal y it shows an error. This is what i try: ``` > cd /usr/bin/ > ./phpdoc.php ``` And this is the error: ``` PHP Warning: include_once(/Applications/MAMP/htdocs/phpdocumentor/src/phpDocumentor/../../vendor/autoload.php): failed to open stream: No such file or directory in /Applications/MAMP/htdocs/phpdocumentor/src/phpDocumentor/Bootstrap.php on line 72 PHP Warning: include_once(): Failed opening '/Applications/MAMP/htdocs/phpdocumentor/src/phpDocumentor/../../vendor/autoload.php' for inclusion (include_path='/Applications/MAMP/bin/php/php5.3.6/lib/php/:/Applications/MAMP/bin/php/php5.3.6/lib/bin/') in /Applications/MAMP/htdocs/phpdocumentor/src/phpDocumentor/Bootstrap.php on line 72 PHP Fatal error: Class 'phpDocumentor_Task_Runner' not found in /Applications/MAMP/htdocs/phpdocumentor/bin/phpdoc.php on line 37 ``` I am using Mac Os X and as you can see, i use MAMP to run Apache. What's going on here? Why it tries to open a file which doesn't exist? (because it really doesn't exist inside PHPDocumentor folder) Thanks.

Original source