As a workaround you can try
Code: Select all
TERM=xterm sudo nano /boot/config.txt
and that should set the terminal type. I think TERM=linux will work if xterm doesn't.
It still doesn't fix the problem, but lets you edit the file locally for now. I'll see if I can remember where/if I saw that about the TERM not being set correctly.