Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save snickerbockers/04f1863f0ded52c0d61f3cd47d4ba26e to your computer and use it in GitHub Desktop.
Save snickerbockers/04f1863f0ded52c0d61f3cd47d4ba26e to your computer and use it in GitHub Desktop.
perl one-liner to turn a text file into a c-string
perl -pe 's;^(.*)$;\"\1\\n\";;' < input.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment