How do I select all text from a file with nano?
Hire the world's top talent on demand or became one of them at Toptal: https://topt.al/25cXVn
and get $2,000 discount on your first invoice
--------------------------------------------------
Music by Eric Matyas
https://www.soundimage.org
Track title: Techno Bleepage Open
--
Chapters
00:00 How Do I Select All Text From A File With Nano?
00:21 Accepted Answer Score 26
00:41 Answer 2 Score 144
01:03 Answer 3 Score 7
01:30 Answer 4 Score 84
01:41 Thank you
--
Full question
https://superuser.com/questions/196425/h...
--
Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...
--
Tags
#linux #copypaste #nano
#avk47
ANSWER 1
Score 144
There is a possible way:
Cursor at the beginning of a file
Ctrl6 to set a mark
AltShiftT (or try AltT) to cut to the end of the file
If AltT doesn't work, try CtrlK
- to just copy the file content do CtrlU to uncut the text again
ANSWER 2
Score 84
you can use cat and then copy it from the console:
cat path/to/file.yml
Select the output printed in the console.
ACCEPTED ANSWER
Score 26
You can't use the buffer of nano
to use it elsewhere, you need to use the buffer of X or Gnome.
xclip is the solution.
A command line interface to the X11 clipboard. It can also be used for copying files, as an alternative to sftp/scp, avoiding password prompts when X11 forwarding has already been setup.
ANSWER 4
Score 7
Actually, this answer might be a bit late but I was looking for an answer for the same question and I just figured it out. when you have the file you want to copy to open in nano. you can hit ctl-R and enter the file you want copied from. this will bring in the whole file.
In my case I was just copying my old fstab so it wasn't a big deal. but could get ridiculous with huge files.