dirsql 0.3.59__tar.gz → 0.3.60__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.
- {dirsql-0.3.59 → dirsql-0.3.60}/Cargo.lock +1 -1
- {dirsql-0.3.59 → dirsql-0.3.60}/PKG-INFO +1 -1
- dirsql-0.3.60/docs/AGENTS.md +95 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/Cargo.toml +1 -1
- dirsql-0.3.60/packages/python/docs/AGENTS.md +95 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/e2e-attestation.json +2 -2
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/db.rs +70 -389
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/persist.rs +8 -7
- dirsql-0.3.59/docs/AGENTS.md +0 -63
- dirsql-0.3.59/packages/python/docs/AGENTS.md +0 -63
- {dirsql-0.3.59 → dirsql-0.3.60}/Cargo.toml +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/README.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/__init__.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/_async.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/_dirsql.pyi +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/cli/__init__.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/cli/binary_path.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/cli/interpret/__init__.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/cli/is_windows.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/cli/main.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/cli/resolve_config_extensions.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/py.typed +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/resolve_config_extensions.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/dirsql/resolve_extension.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/.claude/CLAUDE.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/.vitepress/config.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/.vitepress/theme/index.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/.vitepress/theme/lang.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/api/index.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/cli/config.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/cli/http-api.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/cli/index.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/cli/init.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/cli/server.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/getting-started.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/guide/async.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/guide/crdt.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/guide/persistence.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/guide/querying.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/guide/tables.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/guide/watching.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/index.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/migrations.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/package.json +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/playwright.config.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/pnpm-lock.yaml +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/pnpm-workspace.yaml +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/tests/integration/home.spec.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/tests/integration/language-flag.spec.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/tests/integration/sidebar.spec.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/tests/unit/config.test.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/tests/unit/lang.test.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/docs/vitest.config.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/README.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/conftest.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/.claude/CLAUDE.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/.vitepress/config.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/.vitepress/theme/index.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/.vitepress/theme/lang.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/api/index.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/cli/config.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/cli/http-api.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/cli/index.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/cli/init.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/cli/server.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/getting-started.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/guide/async.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/guide/crdt.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/guide/persistence.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/guide/querying.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/guide/tables.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/guide/watching.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/index.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/migrations.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/package.json +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/playwright.config.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/pnpm-lock.yaml +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/pnpm-workspace.yaml +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/tests/integration/home.spec.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/tests/integration/language-flag.spec.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/tests/integration/sidebar.spec.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/tests/unit/config.test.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/tests/unit/lang.test.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/docs/vitest.config.ts +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/src/lib.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/tests/__init__.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/tests/binding/__init__.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/tests/conftest.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/tests/e2e/__init__.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/tests/integration/__init__.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/python/tests/smoke/__init__.py +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/Cargo.toml +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/README.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/benches/db_bench.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/benches/differ_bench.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/benches/matcher_bench.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/benches/scanner_bench.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/api/index.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/cli/config.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/cli/http-api.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/cli/index.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/cli/init.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/cli/server.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/getting-started.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/guide/async.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/guide/crdt.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/guide/persistence.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/guide/querying.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/guide/tables.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/guide/watching.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/index.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/docs/migrations.md +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/bin/dirsql.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/cli/init.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/cli/mod.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/cli/router.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/cli/serialize.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/cli/server.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/command.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/config.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/differ.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/lib.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/matcher.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/scanner.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/packages/rust/src/watcher.rs +0 -0
- {dirsql-0.3.59 → dirsql-0.3.60}/pyproject.toml +0 -0
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
# Documentation Development
|
|
2
|
+
|
|
3
|
+
Instructions for agents working on `dirsql` documentation.
|
|
4
|
+
|
|
5
|
+
## Stack
|
|
6
|
+
|
|
7
|
+
The docs site uses [VitePress](https://vitepress.dev/). Source files are in `docs/` at the project root.
|
|
8
|
+
|
|
9
|
+
## Running locally
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
cd docs
|
|
13
|
+
pnpm install
|
|
14
|
+
pnpm dev
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
This starts a local dev server (default: `http://localhost:5173/dirsql/`). The site hot-reloads on file changes.
|
|
18
|
+
|
|
19
|
+
## Building
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
cd docs
|
|
23
|
+
pnpm build
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
The build must succeed before pushing. VitePress will fail on broken links, missing assets, and syntax errors in markdown.
|
|
27
|
+
|
|
28
|
+
## Testing changes
|
|
29
|
+
|
|
30
|
+
Before pushing any docs changes:
|
|
31
|
+
|
|
32
|
+
1. Run `pnpm build` in `docs/` and confirm it exits cleanly
|
|
33
|
+
2. Spot-check the built output with `pnpm preview`
|
|
34
|
+
3. Verify sidebar navigation, code blocks, and internal links render correctly
|
|
35
|
+
|
|
36
|
+
## Structure
|
|
37
|
+
|
|
38
|
+
The docs follow the [Diataxis](https://diataxis.fr/) framework. **Type is
|
|
39
|
+
the only organizational axis** -- there are no product-area sections (no
|
|
40
|
+
"CLI" section; #353). The nav and the sidebar mirror the four types exactly.
|
|
41
|
+
|
|
42
|
+
The **primary reader is the CLI user**: someone with a directory of files,
|
|
43
|
+
one command (`uvx` / `npx dirsql`), and a `.dirsql.toml`. The SDKs are the
|
|
44
|
+
secondary audience and appear **only in Reference**, plus the single
|
|
45
|
+
"Embed `dirsql` in your application" how-to.
|
|
46
|
+
|
|
47
|
+
Target tree (the spec for #353; existing pages are *quarried* into it, not
|
|
48
|
+
migrated -- a page survives only if a slot wants its content):
|
|
49
|
+
|
|
50
|
+
- **Tutorial** -- one lesson: *Your first dirsql database*. The reader
|
|
51
|
+
performs every step and sees output at each one; success is
|
|
52
|
+
author-guaranteed (toy dataset, no branching).
|
|
53
|
+
- **How-to Guides** -- goal-named recipes: define tables for your files;
|
|
54
|
+
derive columns from file paths; extract rows from file contents
|
|
55
|
+
(`on-file`); search documents by meaning; skip files; load a SQLite
|
|
56
|
+
extension; keep the index across restarts; react to file changes; embed
|
|
57
|
+
`dirsql` in an application.
|
|
58
|
+
- **Reference** -- CLI flags and defaults; the complete `.dirsql.toml`
|
|
59
|
+
schema; the command hook contract (placeholders, stdout protocol, exit
|
|
60
|
+
codes, timeouts); virtual columns and glob captures; the HTTP API;
|
|
61
|
+
per-language SDK pages (the sole SDK home).
|
|
62
|
+
- **Explanation** -- one page: how `dirsql` thinks (the filesystem is the
|
|
63
|
+
source of truth; the database is a derived, ephemeral, read-only view;
|
|
64
|
+
reconcile and diffing). Its canonical home is the root `ARCHITECTURE.md`;
|
|
65
|
+
#374 surfaces it via an include page, the same mechanism
|
|
66
|
+
`docs/migrations.md` uses for `MIGRATIONS.md`. Edit the root file, never
|
|
67
|
+
a rendered include.
|
|
68
|
+
|
|
69
|
+
Working rules:
|
|
70
|
+
|
|
71
|
+
- **Facts live once, in Reference.** Tutorials and how-tos link to reference
|
|
72
|
+
material; they never re-list constructor parameters or duplicate API tables.
|
|
73
|
+
- **A how-to opens with a 1-2 line goal/motivation statement.** Deep
|
|
74
|
+
rationale (tradeoffs, alternatives considered, theory) moves to Explanation
|
|
75
|
+
only when it is substantial enough to stand alone and is reused across
|
|
76
|
+
pages. Do not manufacture stub pages for a paragraph of "why".
|
|
77
|
+
- **Tutorial vs how-to:** a tutorial is a lesson along a path the author
|
|
78
|
+
guarantees; a how-to serves a competent reader pursuing their own goal.
|
|
79
|
+
- **One global sidebar.** Never add a path-scoped sidebar key -- it swaps
|
|
80
|
+
out the whole tree and hides every other section while inside one (#301;
|
|
81
|
+
see the comment above `sidebar` in `config.ts`).
|
|
82
|
+
|
|
83
|
+
## Conventions
|
|
84
|
+
|
|
85
|
+
- **Lead with the use case.** Open each feature description with *why* a
|
|
86
|
+
reader would reach for it before *how* it works. Don't frame a feature
|
|
87
|
+
by what an adjacent feature can't do.
|
|
88
|
+
*Don't:* "Persistence avoids the thing the default mode can't do..."
|
|
89
|
+
*Do:* "Persistence keeps the SQLite index on disk between runs so large
|
|
90
|
+
directories don't re-scan on every startup."
|
|
91
|
+
- Wrap `dirsql` in backticks in all prose text
|
|
92
|
+
- Use VitePress [code group](https://vitepress.dev/guide/markdown#code-groups) syntax (`::: code-group`) for multi-language examples with `Python`, `Rust`, and `TypeScript` tabs
|
|
93
|
+
- Internal links use relative paths (e.g., `./guide/tables.md`)
|
|
94
|
+
- The VitePress config is at `docs/.vitepress/config.ts`
|
|
95
|
+
- The site is deployed under the `/dirsql/` base path
|
|
@@ -4,7 +4,7 @@ name = "dirsql-py-ext"
|
|
|
4
4
|
# pypi/maturin handler can rewrite it via `write-version` before
|
|
5
5
|
# `maturin build`. `pyproject.toml` declares `dynamic = ["version"]`
|
|
6
6
|
# and maturin reads this field. Mirrors `packages/rust/Cargo.toml`.
|
|
7
|
-
version = "0.3.
|
|
7
|
+
version = "0.3.60"
|
|
8
8
|
edition.workspace = true
|
|
9
9
|
publish = false
|
|
10
10
|
readme = "README.md"
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
# Documentation Development
|
|
2
|
+
|
|
3
|
+
Instructions for agents working on `dirsql` documentation.
|
|
4
|
+
|
|
5
|
+
## Stack
|
|
6
|
+
|
|
7
|
+
The docs site uses [VitePress](https://vitepress.dev/). Source files are in `docs/` at the project root.
|
|
8
|
+
|
|
9
|
+
## Running locally
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
cd docs
|
|
13
|
+
pnpm install
|
|
14
|
+
pnpm dev
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
This starts a local dev server (default: `http://localhost:5173/dirsql/`). The site hot-reloads on file changes.
|
|
18
|
+
|
|
19
|
+
## Building
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
cd docs
|
|
23
|
+
pnpm build
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
The build must succeed before pushing. VitePress will fail on broken links, missing assets, and syntax errors in markdown.
|
|
27
|
+
|
|
28
|
+
## Testing changes
|
|
29
|
+
|
|
30
|
+
Before pushing any docs changes:
|
|
31
|
+
|
|
32
|
+
1. Run `pnpm build` in `docs/` and confirm it exits cleanly
|
|
33
|
+
2. Spot-check the built output with `pnpm preview`
|
|
34
|
+
3. Verify sidebar navigation, code blocks, and internal links render correctly
|
|
35
|
+
|
|
36
|
+
## Structure
|
|
37
|
+
|
|
38
|
+
The docs follow the [Diataxis](https://diataxis.fr/) framework. **Type is
|
|
39
|
+
the only organizational axis** -- there are no product-area sections (no
|
|
40
|
+
"CLI" section; #353). The nav and the sidebar mirror the four types exactly.
|
|
41
|
+
|
|
42
|
+
The **primary reader is the CLI user**: someone with a directory of files,
|
|
43
|
+
one command (`uvx` / `npx dirsql`), and a `.dirsql.toml`. The SDKs are the
|
|
44
|
+
secondary audience and appear **only in Reference**, plus the single
|
|
45
|
+
"Embed `dirsql` in your application" how-to.
|
|
46
|
+
|
|
47
|
+
Target tree (the spec for #353; existing pages are *quarried* into it, not
|
|
48
|
+
migrated -- a page survives only if a slot wants its content):
|
|
49
|
+
|
|
50
|
+
- **Tutorial** -- one lesson: *Your first dirsql database*. The reader
|
|
51
|
+
performs every step and sees output at each one; success is
|
|
52
|
+
author-guaranteed (toy dataset, no branching).
|
|
53
|
+
- **How-to Guides** -- goal-named recipes: define tables for your files;
|
|
54
|
+
derive columns from file paths; extract rows from file contents
|
|
55
|
+
(`on-file`); search documents by meaning; skip files; load a SQLite
|
|
56
|
+
extension; keep the index across restarts; react to file changes; embed
|
|
57
|
+
`dirsql` in an application.
|
|
58
|
+
- **Reference** -- CLI flags and defaults; the complete `.dirsql.toml`
|
|
59
|
+
schema; the command hook contract (placeholders, stdout protocol, exit
|
|
60
|
+
codes, timeouts); virtual columns and glob captures; the HTTP API;
|
|
61
|
+
per-language SDK pages (the sole SDK home).
|
|
62
|
+
- **Explanation** -- one page: how `dirsql` thinks (the filesystem is the
|
|
63
|
+
source of truth; the database is a derived, ephemeral, read-only view;
|
|
64
|
+
reconcile and diffing). Its canonical home is the root `ARCHITECTURE.md`;
|
|
65
|
+
#374 surfaces it via an include page, the same mechanism
|
|
66
|
+
`docs/migrations.md` uses for `MIGRATIONS.md`. Edit the root file, never
|
|
67
|
+
a rendered include.
|
|
68
|
+
|
|
69
|
+
Working rules:
|
|
70
|
+
|
|
71
|
+
- **Facts live once, in Reference.** Tutorials and how-tos link to reference
|
|
72
|
+
material; they never re-list constructor parameters or duplicate API tables.
|
|
73
|
+
- **A how-to opens with a 1-2 line goal/motivation statement.** Deep
|
|
74
|
+
rationale (tradeoffs, alternatives considered, theory) moves to Explanation
|
|
75
|
+
only when it is substantial enough to stand alone and is reused across
|
|
76
|
+
pages. Do not manufacture stub pages for a paragraph of "why".
|
|
77
|
+
- **Tutorial vs how-to:** a tutorial is a lesson along a path the author
|
|
78
|
+
guarantees; a how-to serves a competent reader pursuing their own goal.
|
|
79
|
+
- **One global sidebar.** Never add a path-scoped sidebar key -- it swaps
|
|
80
|
+
out the whole tree and hides every other section while inside one (#301;
|
|
81
|
+
see the comment above `sidebar` in `config.ts`).
|
|
82
|
+
|
|
83
|
+
## Conventions
|
|
84
|
+
|
|
85
|
+
- **Lead with the use case.** Open each feature description with *why* a
|
|
86
|
+
reader would reach for it before *how* it works. Don't frame a feature
|
|
87
|
+
by what an adjacent feature can't do.
|
|
88
|
+
*Don't:* "Persistence avoids the thing the default mode can't do..."
|
|
89
|
+
*Do:* "Persistence keeps the SQLite index on disk between runs so large
|
|
90
|
+
directories don't re-scan on every startup."
|
|
91
|
+
- Wrap `dirsql` in backticks in all prose text
|
|
92
|
+
- Use VitePress [code group](https://vitepress.dev/guide/markdown#code-groups) syntax (`::: code-group`) for multi-language examples with `Python`, `Rust`, and `TypeScript` tabs
|
|
93
|
+
- Internal links use relative paths (e.g., `./guide/tables.md`)
|
|
94
|
+
- The VitePress config is at `docs/.vitepress/config.ts`
|
|
95
|
+
- The site is deployed under the `/dirsql/` base path
|