coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] tr: suggest use of quotes to prevent shell interpolation


From: Pádraig Brady
Subject: Re: [PATCH] tr: suggest use of quotes to prevent shell interpolation
Date: Tue, 6 Jan 2026 18:45:11 +0000
User-agent: Mozilla Thunderbird Beta

On 06/01/2026 01:34, Mason Loring Bliss wrote:
On Tue, Jan 06, 2026 at 12:10:48AM +0000, Pádraig Brady wrote:

We should probably use quoted '[:lower:]' and '[:upper:]' in the text
above at least.

For my part, I like that idea.


On Mon, Jan 05, 2026 at 05:16:25PM -0800, Collin Funk wrote:

Not directly related to your issue, but 'tr' doesn't operate on regular
expressions.

Good point. That's worth a rewording.


Agreed. I think it is probably best to leave the explanation of quoting
to the shell's documentation since it affects so much [2].

It still seems like a good idea to mention that this can happen. It's a
way to keep users from being bitten and it's essentially for free by
mentioning that some of the things tr(1) accepts are of interest to various
shells.

Well we have to be careful about exploding the docs,
but a single line is worth it here.

I'll apply the attached later, and I've also added an entry at:
https://www.pixelbeat.org/docs/coreutils-gotchas.html#tr

cheers,
Padraig

Attachment: tr-warn-about-globbing.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]