We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 08a681b commit c9d579bCopy full SHA for c9d579b
1 file changed
src/replace_everywhere.sh
@@ -108,12 +108,12 @@ main() {
108
fi
109
110
# Execute replacement
111
- # Logic: find . \( PRUNES \) -o -type f -exec sed -i ... '{}' \;
112
- # Using a here-string to keep array expansions intact.
113
if [[ ${#PRUNE_BLOCK[@]} -gt 0 ]]; then
114
- find . \( "${PRUNE_BLOCK[@]}" -false \) -o -type f -exec sed "${SED_INPLACE[@]}" "s/${search}/${replace}/g" {} +
115
- } else
116
- find . -type f -exec sed "${SED_INPLACE[@]}" "s/${search}/${replace}/g" {} +
+ find . \( "${PRUNE_BLOCK[@]}" -false \) -o -type f \
+ -exec sed "${SED_INPLACE[@]}" "s/${search}/${replace}/g" {} +
+ else
+ find . -type f \
117
118
119
echo "Done."
0 commit comments