wexample-wex-addon-dev-javascript 7.14.0__py3-none-any.whl → 7.15.0__py3-none-any.whl

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.
@@ -14,6 +14,7 @@ if TYPE_CHECKING:
14
14
  from wexample_wex_addon_app.service.app_service import AppService
15
15
 
16
16
  _DEFINE_CONFIG_RE = re.compile(r"(defineConfig\(\s*\{)")
17
+ _VITE_CONFIG_NAMES = ("vite.config.ts", "vite.config.js")
17
18
 
18
19
 
19
20
  @command(
@@ -35,7 +36,7 @@ def vite__service__install(
35
36
  ) -> None:
36
37
  app_path = service.app_workdir.get_path()
37
38
 
38
- for config_name in ["vite.config.ts", "vite.config.js"]:
39
+ for config_name in _VITE_CONFIG_NAMES:
39
40
  config_path = app_path / config_name
40
41
  if not config_path.exists():
41
42
  continue
@@ -53,15 +54,16 @@ def vite__service__install(
53
54
  "defineConfig()",
54
55
  "defineConfig({ vite: { server: { allowedHosts: true } } })",
55
56
  )
56
- elif _DEFINE_CONFIG_RE.search(content):
57
- content = _DEFINE_CONFIG_RE.sub(
57
+ else:
58
+ new_content, n = _DEFINE_CONFIG_RE.subn(
58
59
  r"\1 vite: { server: { allowedHosts: true } },",
59
60
  content,
60
61
  count=1,
61
62
  )
62
- else:
63
- context.io.log(f" {config_name}: unrecognized format, skipping")
64
- return
63
+ if not n:
64
+ context.io.log(f" {config_name}: unrecognized format, skipping")
65
+ return
66
+ content = new_content
65
67
 
66
68
  config_path.write_text(content)
67
69
  context.io.log(f" ✓ {config_name}: allowedHosts patched")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: wexample-wex-addon-dev-javascript
3
- Version: 7.14.0
3
+ Version: 7.15.0
4
4
  Summary: Python dev addon for wex
5
5
  Author-Email: weeger <contact@wexample.com>
6
6
  License: MIT
@@ -13,8 +13,8 @@ Requires-Dist: attrs>=23.1.0
13
13
  Requires-Dist: cattrs>=23.1.0
14
14
  Requires-Dist: wexample-api>=6.6.0
15
15
  Requires-Dist: wexample-filestate-javascript>=6.5.0
16
- Requires-Dist: wexample-wex-addon-ai>=11.2.0
17
- Requires-Dist: wexample-wex-addon-app>=26.0.0
16
+ Requires-Dist: wexample-wex-addon-ai>=11.3.0
17
+ Requires-Dist: wexample-wex-addon-app>=26.1.0
18
18
  Provides-Extra: dev
19
19
  Requires-Dist: pytest; extra == "dev"
20
20
  Requires-Dist: pytest-cov; extra == "dev"
@@ -22,7 +22,7 @@ Description-Content-Type: text/markdown
22
22
 
23
23
  # wex_addon_dev_javascript
24
24
 
25
- Version: 7.14.0
25
+ Version: 7.15.0
26
26
 
27
27
  Python dev addon for wex
28
28
 
@@ -106,8 +106,8 @@ Visit the [Wexample Suite documentation](https://docs.wexample.com) for the comp
106
106
  - cattrs: >=23.1.0
107
107
  - wexample-api: >=6.6.0
108
108
  - wexample-filestate-javascript: >=6.5.0
109
- - wexample-wex-addon-ai: >=11.2.0
110
- - wexample-wex-addon-app: >=26.0.0
109
+ - wexample-wex-addon-ai: >=11.3.0
110
+ - wexample-wex-addon-app: >=26.1.0
111
111
 
112
112
  ## Versioning & Compatibility Policy
113
113
 
@@ -1,6 +1,6 @@
1
- wexample_wex_addon_dev_javascript-7.14.0.dist-info/METADATA,sha256=j7-0xHJ30yNoSxM0x3DJ3VDZi9B28DMGSPKxk9BHkWA,17234
2
- wexample_wex_addon_dev_javascript-7.14.0.dist-info/WHEEL,sha256=VP-D4TPS230sME9Z3vb3INXvo1yt0924YRm5AOsk_dE,90
3
- wexample_wex_addon_dev_javascript-7.14.0.dist-info/entry_points.txt,sha256=6OYgBcLyFCUgeqLgnvMyOJxPCWzgy7se4rLPKtNonMs,34
1
+ wexample_wex_addon_dev_javascript-7.15.0.dist-info/METADATA,sha256=vv_hL6x3k8VGEQk_OdNMrxGFRlQQnX0OhAi2i0qoHsE,17234
2
+ wexample_wex_addon_dev_javascript-7.15.0.dist-info/WHEEL,sha256=VP-D4TPS230sME9Z3vb3INXvo1yt0924YRm5AOsk_dE,90
3
+ wexample_wex_addon_dev_javascript-7.15.0.dist-info/entry_points.txt,sha256=6OYgBcLyFCUgeqLgnvMyOJxPCWzgy7se4rLPKtNonMs,34
4
4
  wexample_wex_addon_dev_javascript/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
5
  wexample_wex_addon_dev_javascript/__pycache__/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
6
  wexample_wex_addon_dev_javascript/common/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -30,7 +30,7 @@ wexample_wex_addon_dev_javascript/services/vite/ai/agents/main/agent.yml,sha256=
30
30
  wexample_wex_addon_dev_javascript/services/vite/app_service.py,sha256=X_213Dpa-B0-Jgzp4LdgdhFZhfGp74Upq12aCs5t39Q,658
31
31
  wexample_wex_addon_dev_javascript/services/vite/commands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
32
32
  wexample_wex_addon_dev_javascript/services/vite/commands/service/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
33
- wexample_wex_addon_dev_javascript/services/vite/commands/service/install.py,sha256=HDMv0lbON6zJdMfa8WUxmASgVKW24dbgYVR2WXXqsF8,2299
33
+ wexample_wex_addon_dev_javascript/services/vite/commands/service/install.py,sha256=W2G98WdSXYifIPSUH_Enxa2zQqwSARHG4ZOyQt0zzd8,2363
34
34
  wexample_wex_addon_dev_javascript/services/vite/commands/service/ready.py,sha256=UiPSdN4oSKZmBkE7txE0KwqhI9xLsF_Oz_M6hosssXw,1800
35
35
  wexample_wex_addon_dev_javascript/services/vite/docker/.wex.yml,sha256=JdIF6nGkFcfi76yZYGlXxeWfOK4eAUSV_gAn6i3hk2w,32
36
36
  wexample_wex_addon_dev_javascript/services/vite/docker/docker-compose.yml,sha256=M7ejIcht0GxuEAEEcK3urBIrXA66JwYrr5EPUA9nMMM,595
@@ -39,4 +39,4 @@ wexample_wex_addon_dev_javascript/workdir/__init__.py,sha256=47DEQpj8HBSa-_TImW-
39
39
  wexample_wex_addon_dev_javascript/workdir/javascript_package_workdir.py,sha256=H0-rpqiW9vkl6f_otrBlmNx7ZzAJ54ABhAm4DgziRFY,7486
40
40
  wexample_wex_addon_dev_javascript/workdir/javascript_packages_suite_workdir.py,sha256=b0QoTWlNYOYfpqEb8vYzL4WRoY0WwBhYOFUoRc4oySI,928
41
41
  wexample_wex_addon_dev_javascript/workdir/javascript_workdir.py,sha256=oKBj-tOV-EH9kqiXnKUE7sKLKU4v0ta4IQr-zLEWgFI,5272
42
- wexample_wex_addon_dev_javascript-7.14.0.dist-info/RECORD,,
42
+ wexample_wex_addon_dev_javascript-7.15.0.dist-info/RECORD,,