A command line tool to export, the now deprecated, iTunes Library XML files.
Generate the XML Plist format.
$ itunes-library-export > "~/Music/iTunes/iTunes Music Library.xml"
Alternatively, JSON can also be outputed.
$ itunes-library-export --format json > "~/Music/iTunes/iTunes Music Library.json"
Install with Homebrew.
$ brew install josh/tap/itunes-library-export
Build from source.
$ git clone https://github.com/josh/itunes-library-export
$ cd itunes-library-export
$ swift build -c release
$ cp -f .build/release/itunes-library-export /usr/local/bin/itunes-library-export