14 from Extract.getDef
import getDefFunction
15 from Tool.tool
import getSourceCodePath,resolveConfigFilePath
16 from Tool.workspace
import getRepoRoot
35 print(
"Usage: python extractLibAPI.py -cfg config.json")
43 with open(configPath,
'r',encoding=
'UTF-8')
as fr:
44 libName=json.load(fr)[
'libName']
45 currentVersion, targetVersion, currentSourceCodePath, targetSourceCodePath =
getSourceCodePath(configPath,repoRoot)
48 print(currentVersion, currentSourceCodePath)
49 getLibAPI(currentVersion, libName, currentSourceCodePath)
52 print(targetVersion, targetSourceCodePath)
53 getLibAPI(targetVersion, libName, targetSourceCodePath)
55 if __name__==
'__main__':
def getDefFunction(args)
Extract all lib API definitions from a specified version 抽取给定版本的库API定义
def getRepoRoot()
Get PCART repository root path 获取PCART仓库根目录路径