On Thu, Aug 08, 2019 at 04:33:16PM +0200, Janek Mi wrote: > For some time in my scripts I was using something like this: > > ```shell > #!/usr/bin/env bash > shopt -s failglob > command="echo xyz\(\)" > $command > ``` > > And it was working fine. But somewhere between bash version 4 and 5 I > realized it generates an error: > no match: xyz\(\)
This looks just like another recent thread. See Chet's response here: https://lists.gnu.org/archive/html/bug-bash/2019-08/msg00015.html And my personal response for this variant of the issue: stop putting shell commands in string variables and then trying to run them with unquoted parameter expansion. See: https://mywiki.wooledge.org/BashFAQ/050