def getAppBundleID(path):
    """Returns CFBundleIdentifier if available for application at path."""
    infopath = os.path.join(path, 'Contents', 'Info.plist')
    if os.path.exists(infopath):
        try:
            plist = FoundationPlist.readPlist(infopath)
            if 'CFBundleIdentifier' in plist:
                return plist['CFBundleIdentifier']
        except (__HOLE__,
                FoundationPlist.NSPropertyListSerializationException):
            pass

    return None
dataset/ETHPy150Open munki/munki/code/client/munkilib/updatecheck.py/getAppBundleID