Say, I would like to change my editor system-wide to
nano. I was doing this with
echo 'export EDITOR=/usr/bin/nano' >> /etc/bashrc
As I learned, it was a bad idea, because if you accidentally omit one
>, you will overwrite
bashrc and won't be able to log in. In addition to being error-prone, is this in any other way a bad idea and which way is better?