Monday, July 11, 2016

Midnight UNIX YANK

Today i spent arround 2 hours in digging log files in search of relevant logs to trace through the system behaviour to trouble shoot an issue....

Below are the things i learned,

SCP(Secure Copy) the file from AMAZON EC2
syntax : scp <userName>@<hostName>:<remoteFilePath> <localfile>
scp ec2-user@staging2:/tmp/test1.out .

Copy(YANK) Multiple Lines in VI editor


  1. press Escape to go to VI mode
  2. press V will take to VISUAL mode
  3. select the text to copy(aka) yank
  4. press y.This will copy the contents to REGISTER(CLIPBOARD)
  5. To paste in same file
    1. Place the cursor in the place to copy
    2. press p will paste the contents already copied
  6. To paste in different file
    1. open the another file
      1. : o <filePath>
      2. In the another file press p to Paste

No comments:

Post a Comment