Added more text extensions and give the ability to add in the config.

Using the 'idf_extra_text_ext' configuration variable you can add more
text extensions.
This commit is contained in:
Loic d'Anterroches
2008-12-17 15:08:51 +01:00
parent e282c65bb0
commit d11b107ce1
2 changed files with 7 additions and 2 deletions

View File

@@ -401,7 +401,8 @@ class IDF_Views_Source
if (0 === strpos($fileinfo[0], 'text/')) {
return true;
}
$ext = 'mdtext php js cpp php-dist';
$ext = 'mdtext php js cpp php-dist h gitignore sh py pl rb '
.Pluf::f('idf_extra_text_ext', '');
return (in_array($fileinfo[2], explode(' ', $ext)));
}