Word wrapping in
nano text editor can make scripts and files fail to run/parse properly.
A simple edit can goof up a config or script by adding unwanted newlines.
These settings are in general good for nano on any operating system.
Disable text wrap in nano by adding to
~/.nanorc contains the following for good defaults including Python coding:
set tabsize 4
constantshow: show line and column of cursor position (on old nano version as in Red Hat 7, this option may not be recognized)
tabstospaces: make tabs into 4 spaces
nowrap: disable long-line text wrapping
Nano syntax highlighting is enabled with