plain.dev 0.21.0__tar.gz → 0.22.1__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.
- {plain_dev-0.21.0 → plain_dev-0.22.1}/PKG-INFO +1 -1
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/cli.py +8 -3
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/contribute/cli.py +20 -2
- {plain_dev-0.21.0 → plain_dev-0.22.1}/pyproject.toml +1 -1
- {plain_dev-0.21.0 → plain_dev-0.22.1}/.gitignore +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/LICENSE +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/README.md +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/README.md +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/__init__.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/contribute/README.md +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/contribute/__init__.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/debug.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/default_settings.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/entrypoints.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/gunicorn_logging.json +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/mkcert.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/pdb.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/pid.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/poncho/__init__.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/poncho/color.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/poncho/compat.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/poncho/manager.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/poncho/printer.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/poncho/process.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/precommit/__init__.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/precommit/cli.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/requests.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/services.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/templates/dev/requests.html +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/urls.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/utils.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/plain/dev/views.py +0 -0
- {plain_dev-0.21.0 → plain_dev-0.22.1}/tests/settings.py +0 -0
@@ -219,9 +219,14 @@ class Dev:
|
|
219
219
|
).parent.parent
|
220
220
|
if not settings.PLAIN_TEMP_PATH.exists():
|
221
221
|
settings.PLAIN_TEMP_PATH.mkdir()
|
222
|
-
|
223
|
-
|
224
|
-
|
222
|
+
symlink_path = settings.PLAIN_TEMP_PATH / "src"
|
223
|
+
|
224
|
+
# Remove a broken symlink if it changed
|
225
|
+
if symlink_path.is_symlink() and not symlink_path.exists():
|
226
|
+
symlink_path.unlink()
|
227
|
+
|
228
|
+
if plain_path.exists() and not symlink_path.exists():
|
229
|
+
symlink_path.symlink_to(plain_path)
|
225
230
|
|
226
231
|
def modify_hosts_file(self):
|
227
232
|
"""Modify the hosts file to map the custom domain to 127.0.0.1."""
|
@@ -10,8 +10,11 @@ import click
|
|
10
10
|
@click.option(
|
11
11
|
"--reset", is_flag=True, help="Undo any changes to pyproject.toml and uv.lock"
|
12
12
|
)
|
13
|
+
@click.option(
|
14
|
+
"--all", "all_packages", is_flag=True, help="Link all installed plain packages"
|
15
|
+
)
|
13
16
|
@click.argument("packages", nargs=-1)
|
14
|
-
def cli(packages, repo, reset):
|
17
|
+
def cli(packages, repo, reset, all_packages):
|
15
18
|
"""Contribute to plain by linking packages locally."""
|
16
19
|
|
17
20
|
if reset:
|
@@ -22,7 +25,7 @@ def cli(packages, repo, reset):
|
|
22
25
|
sys.exit(result.returncode)
|
23
26
|
|
24
27
|
click.secho("Running uv sync", bold=True)
|
25
|
-
result = subprocess.run(["uv", "sync"])
|
28
|
+
result = subprocess.run(["uv", "sync", "--reinstall"])
|
26
29
|
if result.returncode:
|
27
30
|
click.secho("Failed to sync", fg="red")
|
28
31
|
sys.exit(result.returncode)
|
@@ -52,6 +55,21 @@ def cli(packages, repo, reset):
|
|
52
55
|
plain_packages = []
|
53
56
|
plainx_packages = []
|
54
57
|
|
58
|
+
if all_packages:
|
59
|
+
# get all installed plain packages
|
60
|
+
output = subprocess.check_output(["uv", "pip", "freeze"])
|
61
|
+
|
62
|
+
installed_packages = output.decode()
|
63
|
+
if not installed_packages:
|
64
|
+
click.secho("No installed packages found", fg="red")
|
65
|
+
sys.exit(1)
|
66
|
+
|
67
|
+
packages = [
|
68
|
+
line.split("==")[0]
|
69
|
+
for line in installed_packages.splitlines()
|
70
|
+
if line.startswith("plain")
|
71
|
+
]
|
72
|
+
|
55
73
|
for package in packages:
|
56
74
|
package = package.replace(".", "-")
|
57
75
|
click.secho(f"Linking {package} to {repo}", bold=True)
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|