The `git ls-files | xargs rm` removes only files; directories which are empty are left laying around. This later chokes the `mv` which puts the "reduced" directory into place. Remove the empty directories as well.
Use the VTK `ThirdParty/update-common.sh` script as of commit 2f24b7b0f60b67a2a28b9aef210f06f904e7a977. Co-Author: Brad King <brad.king@kitware.com>