diff --git a/.github/workflows/sed.sh b/.github/workflows/sed.sh index ef93f45..9c0128f 100755 --- a/.github/workflows/sed.sh +++ b/.github/workflows/sed.sh @@ -1,3 +1,7 @@ #!/usr/bin/env bash -sed -e '/^ *$/d' -e 's/ / /g' -e 's/–/-/g' -e "s/’/'/g" +sed -e '/^ *$/d' `# Whitespace-only or empty lines` \ + -e 's/ / /g' `# nbsp to space` \ + -e 's/–/-/g' `# endash to hyphen` \ + -e "s/’/'/g" `# apostrophe to single quote` \ + -e 's/\s—\s/—/g' `# collapse whitespace around emdash`