CMake simple highlighter

Compatible with: IntelliJ IDEA CLion Android Studio
Dec 25, 2017
1 926
This is the plugin for CMake syntax highlight support.
It provides basic syntax highlight for IntelliJ IDEA CE and Android Studio.
Extend existed highlighting in CLion.

Download plugin

Recent change notes

0.1.0 - CLion support added.
0.0.3 - BraceMatcher added.
0.0.2 - Fix bug of not evaluating escaped escape symbol `\\` inside quoted argument.
0.0.1 - In this version syntax highlighting is provided.

General usage instructions

This is the plugin for CMake syntax highlight support. It provides:

- Basic syntax highlight for IntelliJ IDEA CE and Android Studio.

- Extend existed highlighting in CLion.

The main goal was to make CMakeLists.txt files more readable in Android Studio. It is my play project to study IntelliJ language support. Please see JetBrains manual for more details. Work is still in progress.

Plugin is inspired and based on CMaker by Aliaksandr Dubrouski

CMake Syntax from cmake.org is mostly implemented.


For IntelliJ IDEA CE and Android Studio: Commands, Variables, Properties and Operators was taken from vim CMake support pluging. There are few known syntax highlights bugs, mostly around `$` symbol, because it's used to recognize Variable references in arguments. But those bugs could be reproduced mostly on synthetic tests while real CMakeLists.txt files shown correctly.


For CLion: Commands, Variables, Properties and Operators was taken from official cmake.org manuals. The plugin just adds annotator on top of CLion's builtin CMake support. So all original CLion features (and bugs) works.

In case you don't need such a detailed highlight (i.e. it looks too motley) you can always change colors at plugin settings.