I have a data file that looks like this. I added '%' instead of \t , the tab control character.
1234:56% Alice Worthington alicew% Jan 1, 2010 10:20:30 AM% Closed% Development Digg: Reddit: Update%% file-one.txt% 1.1% c:/foo/bar/quux Add%% file-two.txt% 2.5.2% c:/foo/bar/quux Remove%% file-three.txt% 3.4% c:/bar/quux Update%% file-four.txt% 4.6.5.3% c:/zzz ... many more records of the above form
The entries that interest me are lines starting with Update, Add, Delete, etc. I will not know that lines begin ahead of time or how many lines precede them. I know that they always start with a string of letters followed by two tabs. So I wrote this regex:
generate-report-for 1234:56 | egrep "^[[:alpha:]]+\t\t.+"
But this corresponds to zero lines. Where am I wrong?
Edit: I get the same results if I use '...' or "..." for an egrep expression, so I'm not sure if this is a shell.
source share