0

这个 .bashrc 函数在命令行上运行,它是一个不错的 bash 单行器。

但将其移至 bash 配置文件并停止工作?

replaceInAll (){ find . -name "$1" -print | xargs sed -i 's/$2/$3/g' }

我对此有什么误解?

4

1 回答 1

0

这有效

replaceInAll (){ find . -name "$1" -print | xargs sed -i s/"$2"/"$3"/g }

于 2014-08-29T13:31:38.027 回答