From d1c9467b41581d40bda857ebd07a4463d4186250 Mon Sep 17 00:00:00 2001 From: Christian Schneider Date: Thu, 23 Sep 2010 14:03:17 +0000 Subject: Add support for .no_it_syntaxconvert in directories to ignore them in syntax conversion traversal --- it_auto_prepend.php | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'it_auto_prepend.php') diff --git a/it_auto_prepend.php b/it_auto_prepend.php index 556f167..35014ea 100644 --- a/it_auto_prepend.php +++ b/it_auto_prepend.php @@ -125,11 +125,14 @@ function it_convert($source) { $sourcerelpath = it::replace(array('^(/|\w:)' => ""), $source); # Remove leading / or C: - if (@is_dir($source) && !@is_link($source)) + if (@is_dir($source)) { - ini_set('include_path', $GLOBALS['IT_SYNTAXCONVERTER_DIR'] . "/it_syntaxconverter/$sourcerelpath" . PATH_SEPARATOR . ini_get('include_path')); - foreach (glob("$source/*") as $file) - it_convert($file); + if (!@is_link($source) && !file_exists("$source/.no_it_syntaxconvert")) + { + ini_set('include_path', $GLOBALS['IT_SYNTAXCONVERTER_DIR'] . "/it_syntaxconverter/$sourcerelpath" . PATH_SEPARATOR . ini_get('include_path')); + foreach (glob("$source/*") as $file) + it_convert($file); + } } else if (@is_readable($source)) { -- cgit v1.2.3