xtr-cli 4.0.4__tar.gz → 5.0.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.
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/PKG-INFO +27 -19
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/README.md +25 -17
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/pyproject.toml +2 -2
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/pyproject.toml.orig +2 -2
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/add_on.py +2 -1
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/add_on_catalog.py +27 -11
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/template.py +2 -2
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/README.md.tmpl +1 -1
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/template.toml +3 -3
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/README.md.tmpl +1 -1
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/template.toml +5 -5
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/LICENSE +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/__init__.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/__main__.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/add_on_choice.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/command/__init__.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/command/init_command.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/command/new_command.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/command/serve_command.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/command_support.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/__init__.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/ambiguous_web_entry_point_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/cli_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/directory_not_empty_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/invalid_project_name_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/invalid_template_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/project_not_found_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/step_failed_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/unknown_add_on_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/unknown_template_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/unsupported_python_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/exception/web_entry_point_not_found_error.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/process_runner_interface.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/project_name.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/project_questions.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/project_settings.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/py.typed +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/scaffold_plan.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/scaffolder.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/subprocess_runner.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/template_catalog.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/__init__.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/app/__init__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/app/__main__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/app/command/__init__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/app/command/hello_command.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/app/kernel.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/app/py.typed.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/gitignore.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/pyproject.toml.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/python-version.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/tests/__init__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/tests/test_kernel.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/__init__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/__main__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/command/__init__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/command/hello_command.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/config/__init__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/config/http_kernel.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/kernel.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/py.typed.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/web/__init__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/web/__main__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/web/app.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/web/routes.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/gitignore.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/pyproject.toml.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/python-version.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/tests/__init__.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/tests/test_kernel.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/tests/test_web.py.tmpl +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/web_entry_point.py +0 -0
- {xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/web_entry_point_finder.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: xtr-cli
|
|
3
|
-
Version:
|
|
3
|
+
Version: 5.0.0
|
|
4
4
|
Summary: Scaffolds a new xtr application — a console application or a web application — in one command, and serves it.
|
|
5
5
|
Keywords: scaffold,new project,template,console,web,xtr-dependency-injection
|
|
6
6
|
Author: Xterr
|
|
@@ -15,7 +15,7 @@ Classifier: Programming Language :: Python :: 3.12
|
|
|
15
15
|
Classifier: Programming Language :: Python :: 3.13
|
|
16
16
|
Classifier: Programming Language :: Python :: 3.14
|
|
17
17
|
Classifier: Typing :: Typed
|
|
18
|
-
Requires-Dist: xtr-console>=
|
|
18
|
+
Requires-Dist: xtr-console>=5.0,<6
|
|
19
19
|
Requires-Python: >=3.11
|
|
20
20
|
Description-Content-Type: text/markdown
|
|
21
21
|
|
|
@@ -76,7 +76,7 @@ $ uvx xtr-cli new shop
|
|
|
76
76
|
…
|
|
77
77
|
Add-ons, comma-separated (empty for none): orm, messenger
|
|
78
78
|
Database drivers for orm — sqlite, postgres, mysql, joined with + (sqlite): sqlite+postgres
|
|
79
|
-
Transports and serializers for messenger — amqp,
|
|
79
|
+
Transports and serializers for messenger — amqp, pydantic, joined with +:
|
|
80
80
|
|
|
81
81
|
shop — the webapp template
|
|
82
82
|
--------------------------
|
|
@@ -90,8 +90,8 @@ The same, with no question asked:
|
|
|
90
90
|
Create it? [y/n] (y):
|
|
91
91
|
write pyproject.toml
|
|
92
92
|
…
|
|
93
|
-
run uv add -- 'xtr-dependency-injection
|
|
94
|
-
run uv add --dev -- 'xtr-recipes>=
|
|
93
|
+
run uv add -- 'xtr-dependency-injection>=5.0,<6' …
|
|
94
|
+
run uv add --dev -- 'xtr-recipes>=5.0,<6' pytest httpx ruff basedpyright ty
|
|
95
95
|
run uv run xtr-recipes recipes:sync
|
|
96
96
|
run git init --quiet
|
|
97
97
|
|
|
@@ -188,8 +188,8 @@ application's shutdown hooks run.
|
|
|
188
188
|
|
|
189
189
|
| Template | Packages | Scripts |
|
|
190
190
|
|---|---|---|
|
|
191
|
-
| `cli` | `xtr-dependency-injection`, `xtr-console
|
|
192
|
-
| `webapp` | the same, `xtr-
|
|
191
|
+
| `cli` | `xtr-dependency-injection`, `xtr-console`, `xtr-dotenv`, `xtr-logging` | `<name>` |
|
|
192
|
+
| `webapp` | the same, `xtr-http-kernel`, `fastapi`, `uvicorn` | `<name>`, `<name>-web` |
|
|
193
193
|
|
|
194
194
|
Both write `pyproject.toml` (with ruff, basedpyright, ty and pytest configured), `.python-version`,
|
|
195
195
|
`.gitignore`, `README.md`, `src/<app>/kernel.py`, `src/<app>/__main__.py`, an example
|
|
@@ -205,7 +205,7 @@ a test that requests the home page.
|
|
|
205
205
|
summary = "What it makes, in one line."
|
|
206
206
|
|
|
207
207
|
[dependencies]
|
|
208
|
-
packages = ["xtr-console
|
|
208
|
+
packages = ["xtr-console"] # uv add
|
|
209
209
|
dev = ["xtr-recipes", "pytest"] # uv add --dev; with xtr-recipes, the recipes are applied
|
|
210
210
|
|
|
211
211
|
[files]
|
|
@@ -229,20 +229,28 @@ way it would for a package added later with `xtr-recipes recipes:add`.
|
|
|
229
229
|
|
|
230
230
|
| Add-on | Installs | Variants |
|
|
231
231
|
|---|---|---|
|
|
232
|
-
| `orm` | `xtr-orm
|
|
233
|
-
| `messenger` | `xtr-messenger
|
|
234
|
-
| `scheduler` | `xtr-scheduler[
|
|
235
|
-
| `event-dispatcher` | `xtr-event-dispatcher
|
|
236
|
-
| `cache` | `xtr-cache
|
|
237
|
-
| `lock` | `xtr-lock
|
|
238
|
-
| `rate-limiter` | `xtr-rate-limiter
|
|
239
|
-
| `storage` | `xtr-storage
|
|
240
|
-
| `
|
|
241
|
-
| `
|
|
232
|
+
| `orm` | `xtr-orm` | `sqlite` (default), `postgres`, `mysql` |
|
|
233
|
+
| `messenger` | `xtr-messenger` | `amqp`, `pydantic` |
|
|
234
|
+
| `scheduler` | `xtr-scheduler[cron]` | |
|
|
235
|
+
| `event-dispatcher` | `xtr-event-dispatcher` | |
|
|
236
|
+
| `cache` | `xtr-cache` | `redis` |
|
|
237
|
+
| `lock` | `xtr-lock` | `redis` |
|
|
238
|
+
| `rate-limiter` | `xtr-rate-limiter` | `redis` |
|
|
239
|
+
| `storage` | `xtr-storage` | `s3`, `gcs` |
|
|
240
|
+
| `http-client` | `xtr-http-client` | `http2` |
|
|
241
|
+
| `security` | `xtr-security` — `webapp` only | |
|
|
242
|
+
| `jwt` | `xtr-security-jwt` — `webapp` only; brings `security` | |
|
|
243
|
+
| `oauth2` | `xtr-security-oauth2-server` — `webapp` only; brings `security` and `jwt` | |
|
|
244
|
+
| `webhook` | `xtr-webhook` — `webapp` only; brings `messenger` | |
|
|
245
|
+
|
|
246
|
+
Variants only pick third-party backends. Integrations between xtr packages turn on when both are
|
|
247
|
+
installed: choose `orm` beside `oauth2` to keep its clients in a database, `http-client` beside
|
|
248
|
+
`webhook` to send webhooks, `rate-limiter` beside `http-client` to pace requests.
|
|
242
249
|
|
|
243
250
|
`jwt` boots without a key and signs nothing until one is there: run
|
|
244
251
|
`uv run <name> jwt:generate-keypair --kid jwt --output-dir secrets` for development, and mount
|
|
245
252
|
the deployment's own key in production. No key is ever minted for you.
|
|
253
|
+
`oauth2` likewise issues nothing until its key pair, encryption key and issuer are configured.
|
|
246
254
|
|
|
247
255
|
Variants follow the name after `:`, joined with `+`: `orm:sqlite+postgres`. A name alone takes
|
|
248
256
|
the defaults; `messenger:` picks none. Asked interactively, an add-on with variants is followed by
|
|
@@ -294,7 +302,7 @@ Developed in the [python-xtr](https://github.com/xterr/python-xtr) monorepo, und
|
|
|
294
302
|
`packages/xtr-cli`; run the commands below from there.
|
|
295
303
|
|
|
296
304
|
```sh
|
|
297
|
-
uv sync
|
|
305
|
+
uv sync
|
|
298
306
|
uv run ruff check && uv run ruff format --check && uv run basedpyright && uv run ty check && uv run pytest
|
|
299
307
|
```
|
|
300
308
|
|
|
@@ -55,7 +55,7 @@ $ uvx xtr-cli new shop
|
|
|
55
55
|
…
|
|
56
56
|
Add-ons, comma-separated (empty for none): orm, messenger
|
|
57
57
|
Database drivers for orm — sqlite, postgres, mysql, joined with + (sqlite): sqlite+postgres
|
|
58
|
-
Transports and serializers for messenger — amqp,
|
|
58
|
+
Transports and serializers for messenger — amqp, pydantic, joined with +:
|
|
59
59
|
|
|
60
60
|
shop — the webapp template
|
|
61
61
|
--------------------------
|
|
@@ -69,8 +69,8 @@ The same, with no question asked:
|
|
|
69
69
|
Create it? [y/n] (y):
|
|
70
70
|
write pyproject.toml
|
|
71
71
|
…
|
|
72
|
-
run uv add -- 'xtr-dependency-injection
|
|
73
|
-
run uv add --dev -- 'xtr-recipes>=
|
|
72
|
+
run uv add -- 'xtr-dependency-injection>=5.0,<6' …
|
|
73
|
+
run uv add --dev -- 'xtr-recipes>=5.0,<6' pytest httpx ruff basedpyright ty
|
|
74
74
|
run uv run xtr-recipes recipes:sync
|
|
75
75
|
run git init --quiet
|
|
76
76
|
|
|
@@ -167,8 +167,8 @@ application's shutdown hooks run.
|
|
|
167
167
|
|
|
168
168
|
| Template | Packages | Scripts |
|
|
169
169
|
|---|---|---|
|
|
170
|
-
| `cli` | `xtr-dependency-injection`, `xtr-console
|
|
171
|
-
| `webapp` | the same, `xtr-
|
|
170
|
+
| `cli` | `xtr-dependency-injection`, `xtr-console`, `xtr-dotenv`, `xtr-logging` | `<name>` |
|
|
171
|
+
| `webapp` | the same, `xtr-http-kernel`, `fastapi`, `uvicorn` | `<name>`, `<name>-web` |
|
|
172
172
|
|
|
173
173
|
Both write `pyproject.toml` (with ruff, basedpyright, ty and pytest configured), `.python-version`,
|
|
174
174
|
`.gitignore`, `README.md`, `src/<app>/kernel.py`, `src/<app>/__main__.py`, an example
|
|
@@ -184,7 +184,7 @@ a test that requests the home page.
|
|
|
184
184
|
summary = "What it makes, in one line."
|
|
185
185
|
|
|
186
186
|
[dependencies]
|
|
187
|
-
packages = ["xtr-console
|
|
187
|
+
packages = ["xtr-console"] # uv add
|
|
188
188
|
dev = ["xtr-recipes", "pytest"] # uv add --dev; with xtr-recipes, the recipes are applied
|
|
189
189
|
|
|
190
190
|
[files]
|
|
@@ -208,20 +208,28 @@ way it would for a package added later with `xtr-recipes recipes:add`.
|
|
|
208
208
|
|
|
209
209
|
| Add-on | Installs | Variants |
|
|
210
210
|
|---|---|---|
|
|
211
|
-
| `orm` | `xtr-orm
|
|
212
|
-
| `messenger` | `xtr-messenger
|
|
213
|
-
| `scheduler` | `xtr-scheduler[
|
|
214
|
-
| `event-dispatcher` | `xtr-event-dispatcher
|
|
215
|
-
| `cache` | `xtr-cache
|
|
216
|
-
| `lock` | `xtr-lock
|
|
217
|
-
| `rate-limiter` | `xtr-rate-limiter
|
|
218
|
-
| `storage` | `xtr-storage
|
|
219
|
-
| `
|
|
220
|
-
| `
|
|
211
|
+
| `orm` | `xtr-orm` | `sqlite` (default), `postgres`, `mysql` |
|
|
212
|
+
| `messenger` | `xtr-messenger` | `amqp`, `pydantic` |
|
|
213
|
+
| `scheduler` | `xtr-scheduler[cron]` | |
|
|
214
|
+
| `event-dispatcher` | `xtr-event-dispatcher` | |
|
|
215
|
+
| `cache` | `xtr-cache` | `redis` |
|
|
216
|
+
| `lock` | `xtr-lock` | `redis` |
|
|
217
|
+
| `rate-limiter` | `xtr-rate-limiter` | `redis` |
|
|
218
|
+
| `storage` | `xtr-storage` | `s3`, `gcs` |
|
|
219
|
+
| `http-client` | `xtr-http-client` | `http2` |
|
|
220
|
+
| `security` | `xtr-security` — `webapp` only | |
|
|
221
|
+
| `jwt` | `xtr-security-jwt` — `webapp` only; brings `security` | |
|
|
222
|
+
| `oauth2` | `xtr-security-oauth2-server` — `webapp` only; brings `security` and `jwt` | |
|
|
223
|
+
| `webhook` | `xtr-webhook` — `webapp` only; brings `messenger` | |
|
|
224
|
+
|
|
225
|
+
Variants only pick third-party backends. Integrations between xtr packages turn on when both are
|
|
226
|
+
installed: choose `orm` beside `oauth2` to keep its clients in a database, `http-client` beside
|
|
227
|
+
`webhook` to send webhooks, `rate-limiter` beside `http-client` to pace requests.
|
|
221
228
|
|
|
222
229
|
`jwt` boots without a key and signs nothing until one is there: run
|
|
223
230
|
`uv run <name> jwt:generate-keypair --kid jwt --output-dir secrets` for development, and mount
|
|
224
231
|
the deployment's own key in production. No key is ever minted for you.
|
|
232
|
+
`oauth2` likewise issues nothing until its key pair, encryption key and issuer are configured.
|
|
225
233
|
|
|
226
234
|
Variants follow the name after `:`, joined with `+`: `orm:sqlite+postgres`. A name alone takes
|
|
227
235
|
the defaults; `messenger:` picks none. Asked interactively, an add-on with variants is followed by
|
|
@@ -273,7 +281,7 @@ Developed in the [python-xtr](https://github.com/xterr/python-xtr) monorepo, und
|
|
|
273
281
|
`packages/xtr-cli`; run the commands below from there.
|
|
274
282
|
|
|
275
283
|
```sh
|
|
276
|
-
uv sync
|
|
284
|
+
uv sync
|
|
277
285
|
uv run ruff check && uv run ruff format --check && uv run basedpyright && uv run ty check && uv run pytest
|
|
278
286
|
```
|
|
279
287
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "xtr-cli"
|
|
3
|
-
version = "
|
|
3
|
+
version = "5.0.0"
|
|
4
4
|
description = "Scaffolds a new xtr application — a console application or a web application — in one command, and serves it."
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
requires-python = ">=3.11"
|
|
@@ -24,7 +24,7 @@ classifiers = [
|
|
|
24
24
|
"Programming Language :: Python :: 3.14",
|
|
25
25
|
"Typing :: Typed",
|
|
26
26
|
]
|
|
27
|
-
dependencies = ["xtr-console>=
|
|
27
|
+
dependencies = ["xtr-console>=5.0,<6"]
|
|
28
28
|
|
|
29
29
|
[[project.authors]]
|
|
30
30
|
name = "Xterr"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "xtr-cli"
|
|
3
|
-
version = "
|
|
3
|
+
version = "5.0.0"
|
|
4
4
|
description = "Scaffolds a new xtr application — a console application or a web application — in one command, and serves it."
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
requires-python = ">=3.11"
|
|
@@ -21,7 +21,7 @@ classifiers = [
|
|
|
21
21
|
"Typing :: Typed",
|
|
22
22
|
]
|
|
23
23
|
dependencies = [
|
|
24
|
-
"xtr-console>=
|
|
24
|
+
"xtr-console>=5.0,<6",
|
|
25
25
|
]
|
|
26
26
|
|
|
27
27
|
# `uvx xtr-cli <command>` runs the script named after the distribution; `xtr` is the
|
|
@@ -23,7 +23,8 @@ class AddOn:
|
|
|
23
23
|
name: What ``--with`` calls it.
|
|
24
24
|
summary: One line on what it brings, shown when the add-ons are offered.
|
|
25
25
|
distribution: The package it installs.
|
|
26
|
-
extras: The extras always installed with it
|
|
26
|
+
extras: The extras always installed with it, such as a backend every
|
|
27
|
+
project taking it needs.
|
|
27
28
|
variants: The further extras a project picks between, such as database
|
|
28
29
|
drivers; written after the name as ``orm:sqlite+postgres``.
|
|
29
30
|
default_variants: The variants chosen when the name is given alone.
|
|
@@ -20,7 +20,7 @@ _SHIPPED = (
|
|
|
20
20
|
"orm",
|
|
21
21
|
"Database engines, sessions per unit of work and versioned migrations.",
|
|
22
22
|
"xtr-orm",
|
|
23
|
-
(
|
|
23
|
+
(),
|
|
24
24
|
("sqlite", "postgres", "mysql"),
|
|
25
25
|
("sqlite",),
|
|
26
26
|
"database drivers",
|
|
@@ -29,8 +29,8 @@ _SHIPPED = (
|
|
|
29
29
|
"messenger",
|
|
30
30
|
"A message bus: handlers, middleware, transports and consumers.",
|
|
31
31
|
"xtr-messenger",
|
|
32
|
-
(
|
|
33
|
-
("amqp", "
|
|
32
|
+
(),
|
|
33
|
+
("amqp", "pydantic"),
|
|
34
34
|
(),
|
|
35
35
|
"transports and serializers",
|
|
36
36
|
),
|
|
@@ -38,29 +38,28 @@ _SHIPPED = (
|
|
|
38
38
|
"scheduler",
|
|
39
39
|
"Recurring messages on the bus: cron and intervals.",
|
|
40
40
|
"xtr-scheduler",
|
|
41
|
-
("
|
|
41
|
+
("cron",),
|
|
42
42
|
),
|
|
43
43
|
AddOn(
|
|
44
44
|
"event-dispatcher",
|
|
45
45
|
"Events dispatched to listeners and subscribers by priority.",
|
|
46
46
|
"xtr-event-dispatcher",
|
|
47
|
-
("di", "console"),
|
|
48
47
|
),
|
|
49
48
|
AddOn(
|
|
50
49
|
"cache",
|
|
51
50
|
"Cache pools in memory, in files or in Redis.",
|
|
52
51
|
"xtr-cache",
|
|
53
|
-
(
|
|
52
|
+
(),
|
|
54
53
|
("redis",),
|
|
55
54
|
(),
|
|
56
55
|
"backends",
|
|
57
56
|
),
|
|
58
|
-
AddOn("lock", "Locks around shared resources.", "xtr-lock", (
|
|
57
|
+
AddOn("lock", "Locks around shared resources.", "xtr-lock", (), ("redis",), (), "stores"),
|
|
59
58
|
AddOn(
|
|
60
59
|
"rate-limiter",
|
|
61
60
|
"Limits on how often anything may happen.",
|
|
62
61
|
"xtr-rate-limiter",
|
|
63
|
-
(
|
|
62
|
+
(),
|
|
64
63
|
("redis",),
|
|
65
64
|
(),
|
|
66
65
|
"stores",
|
|
@@ -69,23 +68,40 @@ _SHIPPED = (
|
|
|
69
68
|
"storage",
|
|
70
69
|
"Files on local disk, in memory or in object stores.",
|
|
71
70
|
"xtr-storage",
|
|
72
|
-
(
|
|
71
|
+
(),
|
|
73
72
|
("s3", "gcs"),
|
|
74
73
|
(),
|
|
75
74
|
"object stores",
|
|
76
75
|
),
|
|
76
|
+
AddOn(
|
|
77
|
+
"http-client",
|
|
78
|
+
"An async HTTP client: scoped clients, retries, a pace and a private-network guard.",
|
|
79
|
+
"xtr-http-client",
|
|
80
|
+
(),
|
|
81
|
+
("http2",),
|
|
82
|
+
),
|
|
77
83
|
AddOn(
|
|
78
84
|
"security",
|
|
79
85
|
"Firewalls, authenticators, voters and password hashing.",
|
|
80
86
|
"xtr-security",
|
|
81
|
-
("console",),
|
|
82
87
|
templates=_WEBAPP,
|
|
83
88
|
),
|
|
84
89
|
AddOn(
|
|
85
90
|
"jwt",
|
|
86
91
|
"Self-issued JSON Web Tokens: a token manager and a firewall authenticator.",
|
|
87
92
|
"xtr-security-jwt",
|
|
88
|
-
|
|
93
|
+
templates=_WEBAPP,
|
|
94
|
+
),
|
|
95
|
+
AddOn(
|
|
96
|
+
"oauth2",
|
|
97
|
+
"An OAuth 2.0 authorization server and a resource-server authenticator.",
|
|
98
|
+
"xtr-security-oauth2-server",
|
|
99
|
+
templates=_WEBAPP,
|
|
100
|
+
),
|
|
101
|
+
AddOn(
|
|
102
|
+
"webhook",
|
|
103
|
+
"Webhooks received, verified and turned into events; and sent, signed.",
|
|
104
|
+
"xtr-webhook",
|
|
89
105
|
templates=_WEBAPP,
|
|
90
106
|
),
|
|
91
107
|
)
|
|
@@ -40,8 +40,8 @@ class Template:
|
|
|
40
40
|
summary = "A console application."
|
|
41
41
|
|
|
42
42
|
[dependencies]
|
|
43
|
-
packages = ["xtr-console
|
|
44
|
-
dev = ["xtr-recipes"]
|
|
43
|
+
packages = ["xtr-console"] # installed with `uv add`
|
|
44
|
+
dev = ["xtr-recipes"] # installed with `uv add --dev`
|
|
45
45
|
|
|
46
46
|
[files]
|
|
47
47
|
# destination in the project = template under this directory
|
|
@@ -4,9 +4,9 @@ summary = "A console application: a kernel, its commands, the layered .env files
|
|
|
4
4
|
[dependencies]
|
|
5
5
|
packages = [
|
|
6
6
|
"xtr-dependency-injection",
|
|
7
|
-
"xtr-console
|
|
8
|
-
"xtr-dotenv
|
|
9
|
-
"xtr-logging
|
|
7
|
+
"xtr-console",
|
|
8
|
+
"xtr-dotenv",
|
|
9
|
+
"xtr-logging",
|
|
10
10
|
]
|
|
11
11
|
dev = ["xtr-recipes", "pytest", "ruff", "basedpyright", "ty"]
|
|
12
12
|
|
|
@@ -4,11 +4,11 @@ summary = "A web application: FastAPI served from the kernel, with the console b
|
|
|
4
4
|
|
|
5
5
|
[dependencies]
|
|
6
6
|
packages = [
|
|
7
|
-
"xtr-dependency-injection
|
|
8
|
-
"xtr-console
|
|
9
|
-
"xtr-dotenv
|
|
10
|
-
"xtr-logging
|
|
11
|
-
"xtr-http-kernel
|
|
7
|
+
"xtr-dependency-injection",
|
|
8
|
+
"xtr-console",
|
|
9
|
+
"xtr-dotenv",
|
|
10
|
+
"xtr-logging",
|
|
11
|
+
"xtr-http-kernel",
|
|
12
12
|
"fastapi",
|
|
13
13
|
"uvicorn",
|
|
14
14
|
]
|
|
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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/app/command/__init__.py.tmpl
RENAMED
|
File without changes
|
{xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/cli/files/app/command/hello_command.py.tmpl
RENAMED
|
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
|
{xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/command/__init__.py.tmpl
RENAMED
|
File without changes
|
{xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/command/hello_command.py.tmpl
RENAMED
|
File without changes
|
{xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/config/__init__.py.tmpl
RENAMED
|
File without changes
|
{xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/app/config/http_kernel.py.tmpl
RENAMED
|
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
|
{xtr_cli-4.0.4 → xtr_cli-5.0.0}/src/xtr_cli/templates/webapp/files/tests/test_kernel.py.tmpl
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|