Syntax highlight Makefiles
[gitphp.git] / include / Util.class.php
blob:a/include/Util.class.php -> blob:b/include/Util.class.php
--- a/include/Util.class.php
+++ b/include/Util.class.php
@@ -129,5 +129,24 @@
 		return $filename;
 	}
 
+	/**
+	 * GeshiFilenameToLanguage
+	 *
+	 * Provides a geshi language for a given filename
+	 *
+	 * @access public
+	 * @param string $filename file name
+	 * @return string language
+	 * @static
+	 */
+	public static function GeshiFilenameToLanguage($filename)
+	{
+		if (strncasecmp($filename, 'Makefile', 8) === 0) {
+			return 'make';
+		}
+
+		return null;
+	}
+
 }
 

comments