summaryrefslogtreecommitdiffstats
path: root/application/libraries/Pygments.php
diff options
context:
space:
mode:
Diffstat (limited to 'application/libraries/Pygments.php')
-rw-r--r--application/libraries/Pygments.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/application/libraries/Pygments.php b/application/libraries/Pygments.php
index 62229c472..082c52394 100644
--- a/application/libraries/Pygments.php
+++ b/application/libraries/Pygments.php
@@ -171,6 +171,14 @@ class Pygments {
);
if (array_key_exists($this->filename, $namearray)) return $namearray[$this->filename];
+ $longextarray = array(
+ '.asciinema.json' => 'asciinema',
+ );
+ foreach ($longextarray as $key => $lexer) {
+ if (substr($this->filename, -strlen($key)) === $key) {
+ return $lexer;
+ }
+ }
if (strpos($this->filename, ".") !== false) {
$extension = substr($this->filename, strrpos($this->filename, ".") + 1);