I have been trying to use the sed command to remove lines of what I suspect were Chinese or Japanese translation in text documents. These lines appear to consist mostly of non-ASCII characters like "Šš¥ß€FŠ"
I was hoping that delete lines containing non-ASCII characters:
sed -e '/^[:ascii:]/d' < test1.txt
but this doesn't appear to do anything.
I tried this:
sed -e '/^[\x00 - \x7F]/d' < test1.txt
but again, no luck.
I realise that this is probably because it is finding some ASCII characters in the lines I wish to discard?
Any ideas?
Bookmarks