-   Linux - Software (
-   -   grep for British pound sign? (

ilikejam 12-13-2004 06:50 PM

grep for British pound sign?
Hi all

I'm trying to parse a web page for prices in .

The problem is that grep doesn't recognise the sign, and so doesn't return lines which contain it. Anyone know how this is done?



mikeghet 12-13-2004 07:03 PM

are you able to use ASCII codes???

decimal value 156 = british pound sign.

ilikejam 12-13-2004 07:37 PM

I've sort of solved the problem.

If I convert the web page to UTF-8 (with iconv -f ISO-8859-1 -t UTF-8 go.htm) grep works fine. I think I could probably get a similar effect by changing the $LANG variable, but iconv works for me.

It would be nice if grep could take ASCII codes, but I don't think it does. (There's no mention in the man page).

Cheers anyway.


All times are GMT -5. The time now is 10:38 AM.