(json_file)
| 391 | |
| 392 | |
| 393 | def get_git_urls_from_json(json_file): |
| 394 | with open(json_file, encoding='utf-8') as file: |
| 395 | data = json.load(file) |
| 396 | |
| 397 | custom_nodes = data.get('custom_nodes', []) |
| 398 | git_clone_files = [] |
| 399 | for node in custom_nodes: |
| 400 | if node.get('install_type') == 'git-clone': |
| 401 | files = node.get('files', []) |
| 402 | if files: |
| 403 | git_clone_files.append((files[0], node.get('title'), node.get('preemptions'), node.get('nodename_pattern'))) |
| 404 | |
| 405 | git_clone_files.append(("https://github.com/comfyanonymous/ComfyUI", "ComfyUI", None, None)) |
| 406 | |
| 407 | return git_clone_files |
| 408 | |
| 409 | |
| 410 | def get_py_urls_from_json(json_file): |
no test coverage detected