I have a log file like bellow.
130023432 195047 /media/ismail/SSDWorking/book-collection/_Books/book 1.epub 130023433 195047 /media/ismail/SSDWorking/book-collection/_Books/book 2.epub 130023431 195047 /media/ismail/SSDWorking/book-collection/_Books/book 3.epub
I have a variable,
I want to say if first word equals to
$var, then print all except the first two words.
So, in this case the output will be:
What I have tried so far is
grep -oP "(?<=$var \d+ ).*$'" but it gives error
grep: lookbehind assertion is not fixed length
How can I achieve that?