[TxMt] Leopard Tiger evil pitfall: escaping a backslash in bash

Allan Odgaard throw-away-2 at macromates.com
Thu Apr 17 01:30:56 UTC 2008


On 11 Apr 2008, at 10:19, Hans-Joerg Bibiko wrote:

> [...]
> I tried to get rid of escaping a backslash in bash [...]
>
> Fine. BUT THIS ONLY WORKS UNDER LEOPARD!
>
> Under Tiger I have to write this:
> [...]
> Is this a known issue? If so, is there link to an article mentioning  
> more of them?
>
> [I couldn't find an entry mentioning that macromates.com. Maybe  
> worth to have one.]

In my experience bash variable substitution is buggy or at least very  
limited. As you noticed, backslashes will give problems, but so will  
quotes and regular slashes (escaped).

I have not been able to find any documentation about which rules apply  
to the search and replace string (not even sure I have read anywhere  
that the search string is kind of a glob, but it seems to be iirc).




More information about the textmate mailing list