In vi editor how do you execute unix commands?
Answers were Sorted based on User's Feedback
Answer / km
:! cmd execute a single command (cmd) and return to vi
Is This Answer Correct ? | 22 Yes | 6 No |
Answer / pritesh_8
you can execute as
for example
:filename.c
this will copy current file in vi editor into filename.c
although it is not unix cmd but makes the use of cp cmd
Is This Answer Correct ? | 7 Yes | 3 No |
Answer / ravi kumar.r
compiling filename.c and then execution ./a.out
Is This Answer Correct ? | 6 Yes | 2 No |
Answer / santhosh
we have 3 modes i.e {vi editor}
1.inserted mode
2.extended mode
3.command mode
by default ur in command mode when entering into vi..
if want excute any command just steps are ..
go to command mode i.e ESC+:what command u wish that one
ex-- esc+:pwd
esc+:date
Is This Answer Correct ? | 0 Yes | 0 No |
Hi All, Can you please let me know how to grep for a particular pattern in unix. I want to print the dates from the file exp.txt. the date pattern is DD:MM:YYYY, I just want to print all the dates from the file exp.txt.
8 Answers Concentrix, IBM, Symantec, TCS,
What is the pipe command?
How do I use grep to search for a file?
What does pipe () return?
Give the command to display space usage on the UNIX file system.
what does the 'tee' command do?
What do chmod, chown, chgrp commands do?
Which command is used to find whether the system is 32 bit or 64 bit?
What is the difference between AWK and SED commands? Plz give example and explain...
By using which command we can find the CPU utilization time?
Briefly, how do you install Oracle software on UNIX.
distinguish between paging and swapping?