I have this file named test:http://edge.sharethis.comhttp://edge.sharethis.comhttps://timetosa.comhttp://timetosa.comhttps://webtest.esholahttp.comtimetosaI want a expression that excludes any line that contains timetosa.This is not allowed : cat test | grep -v timetosa, because I want to use a pure regular expression in another program.I know it has to do with ^ but cannot get to the right solution, to affect the ones which not include the string timetosa:cat test | sed 's/^[timetosa]//g' and cat test | sed 's/^(timetosa)//g' without success.Could anyone help me ?
How can I exclude a string using a regular expression?
regular expression