Quick Look for Groovy with Syntax HighlightingIn my previous post OS X: Quick Look for Groovy I showed how to enable Quick Look for Groovy source files.
The result was very cool, but syntax highlighting was missing.
After playing around a bit I found out how to enable syntax highlighting for Groovy in Quick Look.
Here is how it works:
Unfortunately the plugin does not support Groovy out of the box, but we will change that. After installing the plugin you should have the package
QLColorCode.qlgeneratorpackage. Either by right-clicking in Finder and choosing "Show Package Contents" or by navigating into the directory in a shell.
Extend the case-statement in the middle of the script the following way:
This tells Highlight to treat Groovy files as Java source code.
Info.plistinside the QLColorCode.qlgenerator package.
Add the follwing snippet at the end of
Info.plist(just before the ending </array> </dict> </plist>)
QLColorCode.qlgenerator) to the desktop then back to its installed location should do the trick.
This should be it! The result is Quick Look for Groovy with syntax highlighting:
The syntax highlighting is still not perfect, since it is Java highlighting... but it is much better than no highlighting.