Hi Greg,
> I would imagine you were trying to pass a Unicode character. If that's > the case, you need the \u or \U form instead. > > grep $'\u00A0' .XCompose > > Unicode character 00A0 is a non-breaking space. It's not clear whether > that was your intention or not. Yes, that was my intention > > I noticed that there is $ sign before the search string, which I couldn't > > understand. I removed it and re-executed the new grep command grep '\x00A0' > > .XCompose. Now it doesn't return the line > > Uh... you mean you *weren't* trying to grep for non-breaking spaces > in your file using bash's $'...' quoting syntax? You're just typing > something you found at random on the Internet without understanding > it? That's pretty dangerous. Yes, I was trying something that I didn't understand. However, it was not from the internet but given a pretty helpful person in this group. > <https://mywiki.wooledge.org/Quotes> might be good reading for you at > this point. Thanks, will check it out. > 6) The command grep "W" .XCompose | tr $'\xc2\xa0' \! returns > grep "W" .XCompose | tr $'\xc2\xa0' \! > The two hex bytes c2 a0 are the UTF-8 encoding of a non-breaking space, > so it *does* seem like you're chasing after non-breaking spaces for > some reason.... I was trying to find if NBSP are getting added in my .XCompose file > If that's truly your goal, you might also want to pursue configuring > your text editor to show them to you. There are various ways to do > that, depending on which text editor you use. I am using Kate. How can I accomplish that in Kate? > (I don't even know whether you're in a UTF-8 encoding, though, so > who knows whether those are even the correct bytes for an NBSP in> > your locale. You're better off using \u00A0 instead.) No, I don't want to use them. Just wanted to know if they were creeping into my file. Thanks, ajith