File: bin/net_bazzline_api_document_builder

Recommend this page to a friend!
  Classes of nvb  >  PHP API Document Generator  >  bin/net_bazzline_api_document_builder  >  Download  
File: bin/net_bazzline_api_document_builder
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP API Document Generator
Generate automatic documentation for APIs
Author: By
Last change:
Date: 1 year ago
Size: 824 bytes
 

Contents

Class file image Download
#!/usr/bin/env php
<?php
/**
 * @author stev leibelt <artodeto@bazzline.net>
 * @since 2015-05-24
 */

$possiblePathsToComposerAutoloadFile = array(
   
__DIR__ . '/../../../autoload.php',
   
__DIR__ . '/../../vendor/autoload.php',
   
__DIR__ . '/../vendor/autoload.php'
);
$pathToAutoloadFileNotFound = true;
$pathToAutoloadFile = null;

foreach (
$possiblePathsToComposerAutoloadFile as $path) {
    if (
file_exists($path)) {
       
$pathToAutoloadFile = $path;
       
$pathToAutoloadFileNotFound = false;
        break;
    }
}

if (
$pathToAutoloadFileNotFound) {
    echo
'could not find composer autoload.php, no composer installed?' . PHP_EOL;
    exit(
1);
}

require_once
$pathToAutoloadFile;

$command = new \Net\Bazzline\Component\ApiDocumentBuilder\Command\Builder($argv);
$command->execute();

For more information send a message to info at phpclasses dot org.