Skip to content
This repository has been archived by the owner on Jan 14, 2024. It is now read-only.

Commit

Permalink
#47: Escape dollar sign
Browse files Browse the repository at this point in the history
  • Loading branch information
blackandred committed Aug 22, 2020
1 parent 2041e7a commit f3bed3e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rkd/taskutil.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def sh(self, cmd: str, capture: bool = False, verbose: bool = False, strict: boo
env_str = ""

for name, value in env.items():
value = '' if value is None else str(value).replace('"', '\\"')
value = '' if value is None else str(value).replace('"', '\\"').replace('$', '\$')
env_str = env_str + (" export %s=\"%s\";\n" % (name, value))

cmd = env_str + cmd
Expand Down

0 comments on commit f3bed3e

Please sign in to comment.