如果我在命令行中执行了find命令,它就能正常工作,但是如果我在脚本中尝试它,我就会得到这个错误。我运行命令就像files=`find .-type f -regex \".*$ext\" $FILTER`echo "find . -type f -regex \".-type f -regex ".*.cp
我必须编写一个小的bash脚本来确定一个字符串对于bash变量命名规则是否有效。我的脚本接受变量名作为参数。我尝试使用regex将该参数传递给grep命令,但无论我尝试什么,grep都会尝试打开作为文件传递的值。I tried placing it after the command as such
and also tried passing it as redirectedinput, both with