Skip to content

Instantly share code, notes, and snippets.

@rene-d
Forked from JamesChevalier/mac_utf8_insanity.md
Created April 29, 2023 07:02
Show Gist options
  • Save rene-d/dd42ffc8018508a9eebdd4ba07c8209d to your computer and use it in GitHub Desktop.
Save rene-d/dd42ffc8018508a9eebdd4ba07c8209d to your computer and use it in GitHub Desktop.
Unicode on Mac is insane. Mac OS X uses NFD while everything else uses NFC. This fixes that.

convmv manpage

Install convmv if you don't have it

sudo apt-get install convmv

Convert all files in a directory from NFD to NFC:

convmv -r -f utf8 -t utf8 --nfc --notest .

Convert all files in a directory from NFC to NFD:

convmv -r -f utf8 -t utf8 --nfd --notest .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment