Skip to content

Commit 2c335a4

Browse files
committed
Introduce debug flag to enable error reporting
1 parent 5ef29b9 commit 2c335a4

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

phpctags

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
#!/usr/bin/php -q
22
<?php
3-
error_reporting(0);
4-
53
if (is_dir($vendor = __DIR__ . '/vendor')) {
64
require($vendor . '/autoload.php');
75
} elseif (is_dir($vendor = __DIR__ . '/../../../vendor')) {
@@ -15,12 +13,17 @@ if (is_dir($vendor = __DIR__ . '/vendor')) {
1513
}
1614

1715
$options = getopt('f:',array(
16+
'debug',
1817
'excmd::',
1918
'fields::',
2019
'format::',
2120
'version',
2221
));
2322

23+
if(!isset($options['debug'])) {
24+
error_reporting(0);
25+
}
26+
2427
if(isset($options['version'])) {
2528
echo <<<'EOF'
2629
Exuberant Ctags compatiable PHP enhancement, Copyright (C) 2012 Techlive Zheng

0 commit comments

Comments
 (0)