Automatically deleting a line using find, grep, and vim
Hello,
would it be possible the following? Imagine there are multiple files, for instance this.c that.c ... In these files, you want to find a line that contains #include <stdbool.h> and delete the line. Is it possible to do that using find, grep, vim or else? Jaeyong |
Else would be sed.
|
Further Clarification -->
sed -i '#include <stdbool.h>/d' this.c The above command will delete those lines & write to the file. The link below is further info. http://www.thegeekstuff.com/2009/09/...itute-command/ |
Thanks :)
|
All times are GMT -5. The time now is 05:02 AM. |