How would you change all occurrences of a value using VI?

Answer Posted / chitra

One should be in command mode for doing this.(i.e press esc)
:%s/oldpattern/newpattern and press enter

Is This Answer Correct ?    3 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of sed command in unix?

586


What is the comma to show the space allocation of files?

553


What are the general commands in using unix os for a beginner?

575


What is the unix command to confirm a remote host is alive or not?

571


What does pipe () return?

584






Which command will print your home directory on screen?

536


How do I search for a file in unix command?

539


What is the first character of the output in ls l command?

625


What does the metacharacter mean?

604


Is command prompt unix?

570


Name the unix command to find how many days the server has been up.

592


What is unix command?

575


Which command is used to restrict incoming messages?

582


How do I use grep to search for a file?

576


Write a command to display a file’s contents in various formats?

614