2
votes
1answer
251 views

How to delete selected text in nano editor? [duplicate]

How do I delete selected text in the nano editor? I came across this issue while needing to delete the virtual host file and replace its content completely by other content. But the problem is that I ...
0
votes
2answers
71 views

Editing with Nano

Is it possible to edit an existing text file using only one line of command and Nano. For instance if I have a text file called "new.txt" and I want to write "HELLO WORLD" in it. Can I do like this: ...
0
votes
0answers
160 views

Changing nano display color of annotations (#) (globally, regardless of file extension)

Remarks tend to have the form #xy I use red bg for my console which means certain default text colors are hard to decipher. I figured out how I could change colors in my .bashrc and in .nanorc's at ...
1
vote
1answer
291 views

Editing with nano, Alt is caught by the window menus, how can I fix that?

The Alt key is used for many useful commands, but unfortunately it's caught by the terminal window to activate the window menus (File, Edit, ...). I would like to either force the terminal window to ...
23
votes
4answers
81k views

How to edit files in a terminal with nano?

Sometimes, a graphical text editor like gedit or kate cannot be used (because you're in a virtual console for example). Luckily, there are text editors for the terminal. An easy one is nano, but I ...
8
votes
3answers
8k views

Save an edited file in nano, but no permissions

I edited a file in /etc/ that I want to save, but forgot to open it using sudo. I remember there was a command to save such a file in vi, and want to know if there is any such way to do it in nano? ...