GeSHi language file for nginx config

Does anyone have a language file for nginx configurations for the GeSHI
syntax highlighter? Or have you used other syntax highlighter
definitions that I could use to make one? I’ve found one for vim so far
on the web.

Posted at Nginx Forum:,123194,123194#msg-123194


You need to add a line to get_language_name_from_extension() in
extensions/geshi/geshi/geshi.php like this:

‘nginx’ => array()

and save the attached file to extensions/geshi/geshi/geshi/nginx.php.


Thanks much.

Cliff W. Wrote:

found one for vim so far

nginx mailing list
[email protected]

Posted at Nginx Forum:,123194,123210#msg-123210


One of the devs for ‘GeSHi - Generic Syntax Highlighter’ replied back
offered to include the nginx language file in the official distribution
someone is willing to cleanup some of the issues preventing the file
passing the language tests:

I don’t feel I have the necessary skills to do so, but I plan on giving
it a
shot when I get a chance.

Posted at Nginx Forum:,123194,229812#msg-229812

Hi Cliff,

Do you have a recent copy of the nginx.php GeSHi language file? I opened
a request at the SourceForge project tracker here (
) to have the copy you’ve already provided added, but if there is a
newer file I’d like to provide it to them.

Do you happen to have it in a repo somewhere? I looked through the nginx
SVN repo and didn’t see it there.


Posted at Nginx Forum:,123194,229285#msg-229285