Recently I came to know about a site TIO.run . It has almost 97 languages compilers which help you to code and execute. I find it very cool since you don't need to install anythin to try out in your computer , instead write and compile it online. Try tio.run
Sometimes we need to ignore multiple lines with certain words and get the list out of the file. usually it will be a log file to read . The below grep command can be used to ignore multiple words present in a text file. Lets say the file contain $ cat list.txt apple orange apple banana papaya Now we need to ignore line with orange , banana and papaya . So we can use the below grep command. $ cat list.txt | grep -Ev "orange|banana|papaya" apple apple It will ignore lines with the words in -v part of grep.
Comments
Post a Comment