Below command can be used to read Mac OS X version info from a mounted volume
defaults read /Volumes/NameOfVolume/System/Library/CoreServices/SystemVersion ProductVersion
returned value will be something like
10.9
It can be parsed for further processing
defaults read /Volumes/NameOfVolume/System/Library/CoreServices/SystemVersion ProductVersion
returned value will be something like
10.9
It can be parsed for further processing