MCPcopy Create free account
hub / github.com/CheckPointSW/Karta / constructConfigPath

Function constructConfigPath

src/config/utils.py:134–149  ·  view source on GitHub ↗

Generate the name for the JSON config file that will store the library's canonical data. Args: library_name (str): name of the library (as extracted by the identifiers) library_version (str): version of the library (as extracted by the identifiers) Return value: fil

(library_name, library_version)

Source from the content-addressed store, hash-verified

132##################
133
134def constructConfigPath(library_name, library_version):
135 """Generate the name for the JSON config file that will store the library's canonical data.
136
137 Args:
138 library_name (str): name of the library (as extracted by the identifiers)
139 library_version (str): version of the library (as extracted by the identifiers)
140
141 Return value:
142 file name for the JSON config file
143 """
144 global matched_library_name
145
146 # niec hook to save this for future use
147 matched_library_name = library_name
148
149 return library_name + "_" + library_version + ("_windows" if isWindows() else "") + ".json"
150
151def functionsToFile(file_name, contexts):
152 """Store all of the file's functions into a state file.

Callers 3

mainFunction · 0.85
mainFunction · 0.85
matchLibraryFunction · 0.85

Calls 1

isWindowsFunction · 0.85

Tested by

no test coverage detected