From 4b32283b999e05d5b836afd70d854db580bdd9e4 Mon Sep 17 00:00:00 2001 From: Eric Bloch Date: Thu, 11 Jul 2013 23:14:22 -0400 Subject: [PATCH] Add composer depdenency for geshi and update phpdoc to pull in geshi from composer vendor branch when it exists --- composer.json | 3 ++- phpdoc.php | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 21568a9..ccf28f4 100644 --- a/composer.json +++ b/composer.json @@ -12,7 +12,8 @@ ], "require": { "php": ">=5.2.0", - "michelf/php-markdown": "1.3" + "michelf/php-markdown": "1.3", + "easybook/geshi" : "*" }, "require-dev": { "lastcraft/simpletest": "1.1.*" diff --git a/phpdoc.php b/phpdoc.php index f9f1803..fd4834f 100755 --- a/phpdoc.php +++ b/phpdoc.php @@ -35,6 +35,12 @@ set_include_path(get_include_path() . PATH_SEPARATOR . dirname(__FILE__)); require('classes'.DIRECTORY_SEPARATOR.'phpDoctor.php'); +// include geshi from composer if it exists +$phpg = 'vendor'.DIRECTORY_SEPARATOR.'easybook'.DIRECTORY_SEPARATOR.'geshi'.DIRECTORY_SEPARATOR.'geshi.php'; +if (is_readable($phpg)) { + include($phpg); +} + // get name of config file to use if (!isset($argv[1])) { if (isset($_ENV['PHPDoctor'])) {