How to use efpodsanalyzer - 3 common examples

To help you get started, we’ve selected a few efpodsanalyzer examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github EyreFree / EFPodsAnalyzer / efpodsanalyzer / efpodsanalyzer.py View on Github external
podsStringList = podsString.split('\n')
    # 生成原始数据单元数组
    returnList = []
    index = -1
    lastObject = ManifestPodClass('', [])
    for line in podsStringList:
        lineClean = line.replace('\'','').replace('\"','')
        podName = lineClean.lstrip(' -').split(' ')[0]
        if lineClean.startswith('    - '):
            if index >= 0:
                lastObject.podDependencies.append(podName)
        elif lineClean.startswith('  - '):
            if index >= 0:
                returnList.append(lastObject)
            index = index + 1
            lastObject = ManifestPodClass(podName, [])
        else:
            print('Error: The Manifest.lock file is corrupted!')
            exit(ERROR_FILE_CORRUPTED)
    returnList.append(lastObject)
    return returnList
github EyreFree / EFPodsAnalyzer / efpodsanalyzer / efpodsanalyzer.py View on Github external
def readManifestPodListFromFile(fileName):
    fo = open(fileName, "r+")
    manifestFileContent = fo.read()
    fo.close()
    spliteList = manifestFileContent.split('DEPENDENCIES:')
    if len(spliteList) <= 1:
        print('Error: The Manifest.lock file is corrupted!')
        exit(ERROR_FILE_CORRUPTED)
    podsString = '  ' + spliteList[0][5:].strip(' \n')
    podsStringList = podsString.split('\n')
    # 生成原始数据单元数组
    returnList = []
    index = -1
    lastObject = ManifestPodClass('', [])
    for line in podsStringList:
        lineClean = line.replace('\'','').replace('\"','')
        podName = lineClean.lstrip(' -').split(' ')[0]
        if lineClean.startswith('    - '):
            if index >= 0:
                lastObject.podDependencies.append(podName)
        elif lineClean.startswith('  - '):
            if index >= 0:
                returnList.append(lastObject)
            index = index + 1
            lastObject = ManifestPodClass(podName, [])
        else:
            print('Error: The Manifest.lock file is corrupted!')
            exit(ERROR_FILE_CORRUPTED)
    returnList.append(lastObject)
    return returnList
github EyreFree / EFPodsAnalyzer / efpodsanalyzer / efpodsanalyzer.py View on Github external
for index, base in enumerate(baseList):
                if base.podName == dependency:
                    returnList.append(index)
                    tempMark = True
            if False == tempMark:
                return returnList
        return returnList

    returnList = []
    nextList = list(manifestPodList)
    while 0 < len(nextList):
        doingList = list(nextList)
        for manifestPod in doingList:
            baseIndexes = getBaseIndexes(manifestPod.podDependencies, returnList)
            if len(baseIndexes) == len(manifestPod.podDependencies):
                returnList.append(PodClass(manifestPod.podName, baseIndexes))
                nextList.remove(manifestPod)
                # 权重
                for baseIndex in baseIndexes:
                    returnList[baseIndex].podReferenceCount += 1
                    # print(str(baseIndex) + "+= 1, podReferenceCount = " + str(returnList[baseIndex].podReferenceCount))
    return returnList

efpodsanalyzer

CocoaPods dependency analysis tool

GPL-3.0
Latest version published 3 years ago

Package Health Score

51 / 100
Full package analysis

Similar packages