glynnforrest / salt-mode

Emacs major mode for Salt States
GNU General Public License v3.0
22 stars 5 forks source link

Add font lock for top files. #13

Closed joewreschnig closed 7 years ago

joewreschnig commented 7 years ago

Top files are still YAML + Jinja, but rather than states and requisites top files have environments and matches.

joewreschnig commented 7 years ago

Unfortunately I've noticed some weird bugs when first opening top files (they don't get font-locked properly until I save them or mouse-click in them or a few other triggers) so I don't think this is ready to merge yet. I suspect the issue might be MMM-related.

joewreschnig commented 7 years ago

I think this is ready to merge now. The problem was MMM related, viz the temp buffer lacks a filename, but there's already a switch in MMM to let us fake it.

glynnforrest commented 7 years ago

Great stuff, thanks!

I think it might be worth overriding the font-lock keywords from yaml-mode entirely in the future. I have a hunch they are causing some problems with highlighting when a file has a lot of jinja tags.