fast-dev-cli 0.25.9__tar.gz → 0.26.0__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.
- {fast_dev_cli-0.25.9 → fast_dev_cli-0.26.0}/PKG-INFO +1 -1
- fast_dev_cli-0.26.0/fast_dev_cli/__init__.py +1 -0
- {fast_dev_cli-0.25.9 → fast_dev_cli-0.26.0}/fast_dev_cli/cli.py +26 -2
- {fast_dev_cli-0.25.9 → fast_dev_cli-0.26.0}/pyproject.toml +1 -1
- fast_dev_cli-0.25.9/fast_dev_cli/__init__.py +0 -1
- {fast_dev_cli-0.25.9 → fast_dev_cli-0.26.0}/LICENSE +0 -0
- {fast_dev_cli-0.25.9 → fast_dev_cli-0.26.0}/README.md +0 -0
- {fast_dev_cli-0.25.9 → fast_dev_cli-0.26.0}/fast_dev_cli/__main__.py +0 -0
- {fast_dev_cli-0.25.9 → fast_dev_cli-0.26.0}/fast_dev_cli/py.typed +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "0.26.0"
|
|
@@ -283,7 +283,7 @@ def _get_frontend_version() -> tuple[Path, str] | None:
|
|
|
283
283
|
try:
|
|
284
284
|
from asynctor.jsons import json_loads
|
|
285
285
|
except ImportError:
|
|
286
|
-
from json import loads as json_loads # type:ignore[
|
|
286
|
+
from json import loads as json_loads # type:ignore[no-redef]
|
|
287
287
|
content = frontend_version_file.read_bytes()
|
|
288
288
|
metadata: dict[str, str] = json_loads(content) # type:ignore
|
|
289
289
|
try:
|
|
@@ -1270,7 +1270,11 @@ class LintCode(DryRun):
|
|
|
1270
1270
|
quoted_paths = _join_shell_args(path_args)
|
|
1271
1271
|
if path_args != ["."] and all(i.endswith(".html") for i in path_args):
|
|
1272
1272
|
prettier = "prettier"
|
|
1273
|
-
|
|
1273
|
+
abspath = shutil.which(prettier)
|
|
1274
|
+
if abspath is None and (npx := shutil.which("npx")):
|
|
1275
|
+
npx = Path(npx).name.removesuffix(".exe")
|
|
1276
|
+
prettier = f"{npx} prettier"
|
|
1277
|
+
elif is_windows() and abspath:
|
|
1274
1278
|
# If prettier is installed by `npm i -g`
|
|
1275
1279
|
prettier = Path(abspath).name # prettier.CMD
|
|
1276
1280
|
return f"{prettier} -w {quoted_paths}"
|
|
@@ -2247,9 +2251,29 @@ def pypi(
|
|
|
2247
2251
|
):
|
|
2248
2252
|
yellow_warn(f"{p.name!r} not found!")
|
|
2249
2253
|
return
|
|
2254
|
+
if not verbose:
|
|
2255
|
+
verbose = dry and not quiet
|
|
2250
2256
|
UvPypi(p, dry, verbose, quiet, slim, reverse).run()
|
|
2251
2257
|
|
|
2252
2258
|
|
|
2259
|
+
@cli.command()
|
|
2260
|
+
def reverse(
|
|
2261
|
+
file: Annotated[str | None, typer.Argument()] = None,
|
|
2262
|
+
dry: bool = DryOption,
|
|
2263
|
+
verbose: bool = False,
|
|
2264
|
+
quiet: bool = False,
|
|
2265
|
+
) -> None:
|
|
2266
|
+
"""Change registry of uv.lock to be pypi.org"""
|
|
2267
|
+
if not (p := Path(_ensure_str(file) or "uv.lock")).exists() and not (
|
|
2268
|
+
(p := Project.get_work_dir() / p.name).exists()
|
|
2269
|
+
):
|
|
2270
|
+
yellow_warn(f"{p.name!r} not found!")
|
|
2271
|
+
return
|
|
2272
|
+
if not verbose:
|
|
2273
|
+
verbose = dry and not quiet
|
|
2274
|
+
UvPypi(p, dry, verbose, quiet, reverse=True).run()
|
|
2275
|
+
|
|
2276
|
+
|
|
2253
2277
|
class SuffixParser:
|
|
2254
2278
|
usually = ("py", "md", "json", "txt", "proto", "toml")
|
|
2255
2279
|
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "0.25.9"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|