Skip to content

Instantly share code, notes, and snippets.

@neilhwatson
Last active January 18, 2017 17:22
Show Gist options
  • Save neilhwatson/28b8acddcfaf2e2becace34be6686bc5 to your computer and use it in GitHub Desktop.
Save neilhwatson/28b8acddcfaf2e2becace34be6686bc5 to your computer and use it in GitHub Desktop.
Prevent any interpretation in output
cat ~/src/neil/test/v.sh
#!/bin/sh
$variables='Do not show'
x='
Do not expand \\ type escapes and
all $variables
'
printf "$x"
neil@luna:~/src/nextpathway/elt/ambari-config$ ~/src/neil/test/v.sh
/home/neil/src/neil/test/v.sh: 3: /home/neil/src/neil/test/v.sh: =Do not show: not found
Do not expand \ type escapes and
all $variables
## Wrong. Expected to see \\ not \
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment