You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -204,7 +204,7 @@ All tables use `STRICT` mode. Tables marked with `WITHOUT ROWID` store data dire
204
204
| id | INTEGER PK | Auto-increment row id |
205
205
| file_path | TEXT FK | File containing the export |
206
206
| name | TEXT | Exported name |
207
-
| kind | TEXT |`function`, `variable`, etc.|
207
+
| kind | TEXT |`value`, `type`, `re-export`|
208
208
| is_default | INTEGER | 1 if default export |
209
209
| re_export_source | TEXT | Source module if re-exported |
210
210
@@ -327,7 +327,7 @@ The indexer uses git to detect changes since the last indexed commit:
327
327
328
328
1.**Stores `last_indexed_commit`** (HEAD SHA) in the `meta` table after each run
329
329
2. On next run, computes `git diff --name-only <last_commit>..HEAD` + `git status --porcelain`
330
-
3. Only re-indexes changed files (Wyhash content comparison), using DB-sourced `indexedPaths` for import resolution (skips full `collectFiles()` glob scan)
330
+
3. Only re-indexes changed files (SHA-256 content comparison), using DB-sourced `indexedPaths` for import resolution (skips full `collectFiles()` glob scan)
331
331
4. Deleted files are removed via `ON DELETE CASCADE` — deleting from `files` cascades to all related tables
332
332
5. Falls back to full rebuild if commit history is incompatible (e.g. force push, branch switch)
333
333
@@ -436,7 +436,7 @@ Until the first release, Codemap keeps **`SCHEMA_VERSION` at 1**; pull `--full`
436
436
437
437
### `bun:sqlite` API
438
438
439
-
All DDL and PRAGMA statements use `Database.run()` (not the deprecated `Database.exec()` alias). Parameterized insert/update statements use `Database.query()`(which caches compiled statements) instead of `Database.prepare()` (which does not cache). Read queries also use `Database.query().all()` or `.get()`. Bulk inserts use the generic `batchInsert<T>()` helper with multi-row `INSERT ... VALUES (...),(...),(...)` in batches of 100, pre-computed placeholders, and zero-copy index-bounds iteration.
439
+
All DDL and PRAGMA statements use `Database.run()`. The `sqlite-db.ts` wrapper abstracts both Bun (`bun:sqlite`) and Node (`better-sqlite3`). On Bun, `Database.query()` caches compiled statements; on Node, `better-sqlite3` re-prepares on each call via the wrapper's `run()` method. Read queries use the wrapper's `.query().all()` or `.get()`. Bulk inserts use the generic `batchInsert<T>()` helper with multi-row `INSERT ... VALUES (...),(...),(...)` in batches of 100, pre-computed placeholders, and zero-copy index-bounds iteration.
0 commit comments