Skip to content

Instantly share code, notes, and snippets.

@YSaxon
Forked from kamermans/fix_quotes.sh
Last active October 25, 2021 17:10
Show Gist options
  • Save YSaxon/2a4709fea0d3bf6be199bfa3320c7d7c to your computer and use it in GitHub Desktop.
Save YSaxon/2a4709fea0d3bf6be199bfa3320c7d7c to your computer and use it in GitHub Desktop.
Replace fancy-quotes / curly-quotes / smart-quotes with standard ASCII single- and double-quotes in bash
#modified to work inline on stdin
sed "s/[$(echo -ne '\u00B4\u2018\u2019')]/'/g; s/[$(echo -ne '\u201C\u201D')]/\"/g"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment