I tried to use grep to search for lines containing the word "bead" using "\b" but it doesn't find the lines containing the word "bead" separated by space. I tried this script:
cat in.txt | grep -i "\bbead\b" > out.txt
I get results like
- Bead, 3 sided MET DP110317.jpg
- Bead. -2819 (FindID 10143).jpg
- Bead(Gem), Artefacts of Phu Hoa site(Dong Nai province).jpg
- Romano-British pendant amulet (bead) (FindID 241983).jpg
But I don't get the results like
- Bead fun.jpg
Instead of getting some 2,000 lines, I'm only getting 92 lines
My OS is Windows 10 - 64 bit but I'm using grep 2.5.4 from the GnuWin32 package.
I've also tried the MSYS2, which includes grep 3.0 but it does the same thing.
And then, how can I search for words separated by space?