How to add content of one file into another file at the beginning

Answer Posted / green

(To insert file2 content to file1; then the command is)
vi file1
(in command mode)
:0 r! cat file2 (press enter)

( file2 content is inserted to file1 )

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is awk good for?

582


How do I delete files from command prompt?

549


What does the md command do?

568


What does awk stand for?

603


Which command will print your home directory on screen?

540






Enumerate some of the most commonly used network commands in unix?

614


What do chown command do?

532


How do you repeat a command in terminal?

587


What does the command '$ls | wc –l > file1' do?

676


Which command can you use to find the currently running process in unix server?

583


how to sort the content of the file based on numeric values

1247


How do I run a bash script?

578


What is in grep command?

645


Which command is used to restrict incoming messages?

592


Enlist some filename manipulation commands in unix.

547