This should be easy: I want to run sed against a literal string, not an input file. If you wonder why, it is to, for example edit values stored in variabl
My version using variables in a bash script:
Find any backslashes and replace with forward slashes:
input="This has a backslash \\" output=$(echo "$input" | sed 's,\\,/,g') echo "$output"