Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

6
  • When I run this command, I get ', 'stringr23aphics as the output. Commented Jan 17, 2017 at 20:21
  • @fbt See my latest note. Commented Jan 17, 2017 at 20:31
  • 2
    print p"'"'"'"$0"'"'"'"; p=", "—holy quotes, Batman! Commented Jan 17, 2017 at 21:23
  • I know, right‽ :) I thought about mentioning that in many shells print p"'\''"$0"'\''"; would have also worked (it's not POSIXy though), or alternatively using bash's C quoting strings ($'') even just print p"\'"$0"\'"; (might have required doubling other backslashes though) but there's already the other method using awk's character escapes. Commented Jan 17, 2017 at 21:41
  • Wow, I can't believe you figured that out. Thank you. Commented Jan 18, 2017 at 17:44