Add comparator for .dmg files (MacOS disk image)
.dmg files are MACOSX installer files, comparing them result in binary diff, examples:
Below files return for file zlib compressed data
https://github.com/audacity/audacity/releases/download/Audacity-3.0.0/audacity-macos-3.0.0.dmg
https://github.com/audacity/audacity/releases/download/Audacity-3.0.2/audacity-macos-3.0.2.dmg
https://github.com/maculateConception/aural-player/releases/download/2.12.1/AuralPlayer-2.12.1.dmg https://github.com/maculateConception/aural-player/releases/download/2.12.0/AuralPlayer-2.12.0.dmg
Below files return for file lzfse encoded, lzvn compressed
https://github.com/BlueWallet/BlueWallet/releases/download/v6.0.2/BlueWallet.6.0.2.dmg
https://github.com/BlueWallet/BlueWallet/releases/download/v6.0.1/BlueWallet.6.0.1.dmg
.dmg files can be sometimes extracted by: (the .dmg files vary in various details such as compression used & type, etc...)
-
7z x filename.dmgfromp7zip-fullpackage (in above links work only on AuralPlayer app). -
dmg2img filename.dmg filename.imgcommand fromdmg2imgpackage convert the .dmg file to .img file, but the result is still file which diffoscope don't recognize and thus binary diff is shown, file for them returndataor:DOS/MBR boot sector; partition 1 : ID=0xee, start-CHS (0x3ff,254,63), end-CHS (0x3ff,254,63), startsector 1, 105122 sectors, extended partition table (last) - using
unhfscommand from hfsexplorer: https://github.com/unsound/hfsexplorer/releases/ https://stackoverflow.com/questions/59960134/need-command-line-tools-to-extract-binaries-from-dmg-file-on-osx - mount the image:
sudo mount -t hfsplus filename.dmg /mnt(typehfsorhfsplus)
More info & other tools: https://en.wikipedia.org/wiki/Apple_Disk_Image https://askubuntu.com/questions/38112/how-can-i-open-a-dmg-file