MCPcopy Index your code
hub / github.com/StackStorm/st2 / main

Function main

tools/json2yaml.py:74–83  ·  view source on GitHub ↗
(dir_, skip_convert)

Source from the content-addressed store, hash-verified

72
73
74def main(dir_, skip_convert):
75 files = get_files_matching_pattern(dir_, "*.json")
76 if skip_convert:
77 PRINT(files)
78 return
79 results = [json_2_yaml_convert(filename) for filename in files]
80 PRINT("*** conversion done ***")
81 PRINT(["converted {} to {}".format(result[0], result[1]) for result in results])
82 results = [git_rm(filename) for filename, new_filename in results if new_filename]
83 PRINT("*** git rm done ***")
84
85
86if __name__ == "__main__":

Callers 1

json2yaml.pyFile · 0.70

Calls 4

json_2_yaml_convertFunction · 0.85
git_rmFunction · 0.85
formatMethod · 0.45

Tested by

no test coverage detected