Cool! Thanks
I'm no programmer but I think I can handle it after clearing up a few things:
1) I already have the installer (I made a DMG file out of it, from the Snow Leopard installer DVD), so I assume I can remove the following section, right?
Code:
if [ ! -f /Applications/Install\ OS\ X\ Mavericks.app/Contents/SharedSupport/InstallESD.dmg ]; then
echo "Download the OS X Mavericks App and then rerun this script."
open "https://itunes.apple.com/us/app/os-x-mavericks/id675248567"
exit 1
fi
2) I already have a DMG file (I believe I used
Disk Utility to make that disk image from the Snow Leopard installation DVD back when I bought it, so I could have a hard-drive backup copy). If I double-click the DMG file it opens with the same contents as of the DVD. There's an app there (with a "prohibited" icon over it, indicating that I can't even install it from MacOS 10.13 High Sierra that I'm currently using) named "Install Mac OS X" (and if I right click and select "Get info" it shows it to be a .app file). Is this equivalent to the "Mavericks.app" file below? If so, I have a problem as I can't find anything similar to the file structure below, nor is there a DMG file in there (I right-clicked on the installer app and chose "Show package contents"):
Code:
# Mount the installer image
hdiutil attach /Applications/Install\ OS\ X\ Mavericks.app/Contents/SharedSupport/InstallESD.dmg -noverify