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 .
Take a look at https://github.com/cr0sh/jaso for a faster alternative written in Rust.