comfy-cli 0.0.20.dev0__tar.gz → 0.0.20.dev1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/PKG-INFO +1 -1
  2. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/cmdline.py +14 -1
  3. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/config_manager.py +4 -24
  4. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/tracking.py +11 -7
  5. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli.egg-info/PKG-INFO +1 -1
  6. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/pyproject.toml +1 -1
  7. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/LICENSE +0 -0
  8. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/README.md +0 -0
  9. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/__init__.py +0 -0
  10. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/__main__.py +0 -0
  11. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/command/__init__.py +0 -0
  12. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/command/custom_nodes/__init__.py +0 -0
  13. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/command/custom_nodes/command.py +0 -0
  14. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/command/install.py +0 -0
  15. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/command/models/models.py +0 -0
  16. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/command/run.py +0 -0
  17. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/constants.py +0 -0
  18. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/env_checker.py +0 -0
  19. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/logging.py +0 -0
  20. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/registry/__init__.py +0 -0
  21. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/registry/api.py +0 -0
  22. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/registry/config_parser.py +0 -0
  23. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/registry/types.py +0 -0
  24. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/registry/zip.py +0 -0
  25. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/ui.py +0 -0
  26. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/update.py +0 -0
  27. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/utils.py +0 -0
  28. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli/workspace_manager.py +0 -0
  29. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli.egg-info/SOURCES.txt +0 -0
  30. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli.egg-info/dependency_links.txt +0 -0
  31. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli.egg-info/entry_points.txt +0 -0
  32. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli.egg-info/requires.txt +0 -0
  33. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/comfy_cli.egg-info/top_level.txt +0 -0
  34. {comfy_cli-0.0.20.dev0 → comfy_cli-0.0.20.dev1}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: comfy-cli
3
- Version: 0.0.20.dev0
3
+ Version: 0.0.20.dev1
4
4
  Summary: A CLI tool for installing and using ComfyUI.
5
5
  Maintainer-email: Yoland Yan <yoland@drip.art>, James Kwon <hongilkwon316@gmail.com>, Robin Huang <robin@drip.art>, "Dr.Lt.Data" <dr.lt.data@gmail.com>
6
6
  License: GNU GENERAL PUBLIC LICENSE
@@ -82,10 +82,13 @@ def entry(
82
82
  help="Execute from current path",
83
83
  callback=exclusivity_callback,
84
84
  ),
85
+ yes: bool = typer.Option(
86
+ False, "--yes", "-y", help="Enable without confirmation", is_flag=True
87
+ ),
85
88
  ):
86
89
  workspace_manager.setup_workspace_manager(workspace, here, recent)
87
90
 
88
- tracking.prompt_tracking_consent()
91
+ tracking.prompt_tracking_consent(yes)
89
92
 
90
93
  if ctx.invoked_subcommand is None:
91
94
  print(
@@ -152,6 +155,14 @@ def install(
152
155
  callback=gpu_exclusivity_callback,
153
156
  ),
154
157
  ] = None,
158
+ cpu: Annotated[
159
+ bool,
160
+ typer.Option(
161
+ show_default=False,
162
+ help="Install for CPU",
163
+ callback=gpu_exclusivity_callback,
164
+ ),
165
+ ] = None,
155
166
  commit: Annotated[
156
167
  Optional[str], typer.Option(help="Specify commit hash for ComfyUI")
157
168
  ] = None,
@@ -203,6 +214,8 @@ def install(
203
214
  gpu = GPU_OPTION.AMD
204
215
  elif m_series:
205
216
  gpu = GPU_OPTION.M_SERIES
217
+ elif cpu:
218
+ gpu = None
206
219
  else:
207
220
  if platform == constants.OS.MACOS:
208
221
  gpu = ui.prompt_select_enum(
@@ -1,8 +1,6 @@
1
1
  import configparser
2
2
  import os
3
3
 
4
- import tomlkit
5
-
6
4
  from comfy_cli.utils import singleton, get_os, is_running
7
5
  from comfy_cli import constants, logging
8
6
  from typing import Optional, Tuple
@@ -20,11 +18,6 @@ class ConfigManager(object):
20
18
  def get_config_path():
21
19
  return constants.DEFAULT_CONFIG[get_os()]
22
20
 
23
- @staticmethod
24
- def get_pyproject_path():
25
- # TODO: check if this works for homebrew and pip installed comfy-cli as well.
26
- return os.path.join(os.path.dirname(__file__), "../pyproject.toml")
27
-
28
21
  def get_config_file_path(self):
29
22
  return os.path.join(self.get_config_path(), "config.ini")
30
23
 
@@ -126,26 +119,13 @@ class ConfigManager(object):
126
119
  self.background = None
127
120
 
128
121
  def get_cli_version(self):
129
- # First, try reading from pyproject.toml
130
- try:
131
- with open(self.get_pyproject_path(), "r") as f:
132
- pyproject_toml_content = f.read()
133
- parsed_toml = tomlkit.parse(pyproject_toml_content)
134
- return parsed_toml["project"]["version"]
135
- except FileNotFoundError:
136
- logging.debug("pyproject.toml not found.")
137
- except KeyError:
138
- logging.warning("Version key not found in pyproject.toml.")
139
- except Exception as e:
140
- logging.warning(
141
- f"Error occurred while retrieving CLI version from pyproject.toml: {e}"
142
- )
143
-
144
- # If the above fails, fall back to using importlib.metadata
122
+ # Note: this approach should work for users installing the CLI via PyPi (e.g., pip install comfy-cli)
145
123
  try:
146
124
  return version("comfy-cli")
147
125
  except Exception as e:
148
126
  logging.debug(
149
127
  f"Error occurred while retrieving CLI version using importlib.metadata: {e}"
150
128
  )
151
- return "unknown"
129
+
130
+ # TODO: cover the users installing the CLI via homebrew
131
+ return "0.0.0"
@@ -1,10 +1,11 @@
1
1
  import functools
2
+ import logging as logginglib
2
3
  import os
3
4
  import uuid
4
- import logging as logginglib
5
- from mixpanel import Mixpanel, MixpanelException
6
5
 
7
6
  import typer
7
+ from mixpanel import Mixpanel
8
+
8
9
  from comfy_cli import logging, ui, constants
9
10
  from comfy_cli.config_manager import ConfigManager
10
11
 
@@ -88,15 +89,18 @@ def track_command(sub_command: str = None):
88
89
  return decorator
89
90
 
90
91
 
91
- def prompt_tracking_consent():
92
+ def prompt_tracking_consent(yes: bool = False):
92
93
  tracking_enabled = config_manager.get(constants.CONFIG_KEY_ENABLE_TRACKING)
93
94
  if tracking_enabled is not None:
94
95
  return
95
96
 
96
- enable_tracking = ui.prompt_confirm_action(
97
- "Do you agree to enable tracking to improve the application?"
98
- )
99
- init_tracking(enable_tracking)
97
+ if yes:
98
+ init_tracking(True)
99
+ else:
100
+ enable_tracking = ui.prompt_confirm_action(
101
+ "Do you agree to enable tracking to improve the application?"
102
+ )
103
+ init_tracking(enable_tracking)
100
104
 
101
105
 
102
106
  def init_tracking(enable_tracking: bool):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: comfy-cli
3
- Version: 0.0.20.dev0
3
+ Version: 0.0.20.dev1
4
4
  Summary: A CLI tool for installing and using ComfyUI.
5
5
  Maintainer-email: Yoland Yan <yoland@drip.art>, James Kwon <hongilkwon316@gmail.com>, Robin Huang <robin@drip.art>, "Dr.Lt.Data" <dr.lt.data@gmail.com>
6
6
  License: GNU GENERAL PUBLIC LICENSE
@@ -5,7 +5,7 @@ build-backend = "setuptools.build_meta"
5
5
  [project]
6
6
  name = "comfy-cli"
7
7
  license = {file = "LICENSE"}
8
- version = "0.0.20.dev" # Will be filled in by the CI/CD pipeline. Check publish_package.py.
8
+ version = "0.0.20.dev1" # Will be filled in by the CI/CD pipeline. Check publish_package.py.
9
9
  requires-python = ">= 3.9"
10
10
  description = "A CLI tool for installing and using ComfyUI."
11
11
  readme = "README.md"
File without changes