I need a command that grep command to find a text after the matching pattern until the space.
I have a line in a file
shell="/mix/delta/LINUX"
and I need the output only as LINUX
.
The below command give the output delta/LINUX
,
grep -o 'delta/[^"]*' file.txt
What I need is only LINUX
. Please let me know what to change in this to get the expected output.
shell=
or the only one containingdelta/
, or is there any other criterion?