seanomlor seanomlor - 1 year ago 91
Linux Question

How to turn OFF (or at least override) syntax highlighting in nano via ~/.nanorc?

I am struggling finding a clear answer on disabling or overriding the color settings for the nano editor.

By default color syntax highlighting is enabled on my system. Clicking ALT+Y disables this, which is exactly what I want my default to be.

Any ideas?

Answer Source

To disable syntax highlighting write following lines into ~/.nanorc

set quiet
syntax "disabled" "."

The first line prevent error reporing. The second line defines a new color syntax.

You can also define a single syntax containing your favorite color in your ~/.nanorc

syntax "disabled" "."
color brightgreen,black "."

I hope this helps.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download