Skip to content

Commit

Permalink
fix: correctly escape dollars within scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
tboerger committed Aug 31, 2024
1 parent f75062b commit c8a29b2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion profiles/shared/programs/develop.nix
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ in
has_error=0
ag -l $word $hidden "$1" | while read file; do
sed -i.bak "s|${word:+[[:<:]]}$1${word:+[[:>:]]}|$2|g" "$file"
sed -i.bak "s|''${word:+[[:<:]]}$1''${word:+[[:>:]]}|$2|g" "$file"
if diff -q "$file" "$file.bak" >/dev/null; then
echo "Warning: $file: pattern found, but no substitutions made" >&2
Expand Down

0 comments on commit c8a29b2

Please sign in to comment.