![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| set EDITOR=vi -> default editor not setting for cron tab | aarora_98 | Shell Programming and Scripting | 6 | 09-12-2008 11:01 PM |
| How to select Test in Vi Editor | Aejaz | UNIX for Advanced & Expert Users | 2 | 04-30-2008 08:55 AM |
| Awk - select from a list | simha77777 | UNIX for Dummies Questions & Answers | 14 | 02-07-2008 09:42 AM |
| Out put with select date. Help !!! | sabercats | Shell Programming and Scripting | 4 | 02-27-2006 02:52 PM |
| select() and read() | jnuno | High Level Programming | 2 | 11-19-2002 11:03 AM |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hi all,
How can i select all and copy text in VI Editor. Rakesh Gupta |
| Forum Sponsor | ||
|
|
|
#2
|
|||
|
|||
|
The only thought I have is to go to the top line of your document and do "yyX", where X is the number of lines in your doc. That will yank all the lines into the buffer. Then put your cursor where you want the copy to go and do a "p"
|
|
#3
|
|||
|
|||
|
Is there no other way as with yyX i would have to know the number of lines in advance (though its not a problem) but still if there is shorter way please point it out.
Thanks for the reply, Rakesh |
|
#4
|
|||
|
|||
|
You can do it this way also, which doesn't require you to know the number of lines:
Code:
:%Y a Then, when you want to paste, position your cursor where you want it and type this in (without being in command mode): Paste below the cursor position: Code:
"ap Paste above the cursor position: Code:
"aP |
|
#5
|
||||
|
||||
|
I tried
Quote:
Quote:
Quote:
I think we sould type : Quote:
|
|
#6
|
|||
|
|||
|
My bad, it was a typo.
|
|
#7
|
|||
|
|||
|
Hi,
Can you elaborate pls. Does the command allow you to paste it another file? I tried but it would not work. Any clue? Thanks |
|||
| Google The UNIX and Linux Forums |