I want to use sed to replace every occurrence of /dir with $dir (replace / with $) in every script
- by gm
use sed to replace every occurrence of /dir with $dir (replace / with $) in every script in a directory.
sed "s#/dir#$dir#g"
The $ keeps being interpreted as a function or variable call.
Is there a way around this?
thanks