/usr/bin/find: cannot build its arguments dynamically
问题 The following command works as expected interactively, in a terminal. $ find . -name '*.foo' -o -name '*.bar' ./a.foo ./b.bar $ However , if I do this, I get no results! $ ftypes="-name '*.foo' -o -name '*.bar'" $ echo $ftypes -name '*.foo' -o -name '*.bar' $ find . $ftypes $ My understanding was/is that $ftypes would get expanded by bash before find got a chance to run. In which case, the ftypes approach should also have worked. What is going on here? Many thanks in advance. PS: I have a