dirsql 0.3.123__tar.gz → 0.3.124__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.
Files changed (198) hide show
  1. {dirsql-0.3.123 → dirsql-0.3.124}/Cargo.lock +1 -1
  2. {dirsql-0.3.123 → dirsql-0.3.124}/PKG-INFO +2 -2
  3. {dirsql-0.3.123/packages/python → dirsql-0.3.124}/README.md +1 -1
  4. {dirsql-0.3.123/packages/rust → dirsql-0.3.124}/docs/getting-started.md +4 -4
  5. {dirsql-0.3.123/packages/python → dirsql-0.3.124}/docs/howto/load-extension.md +1 -1
  6. {dirsql-0.3.123/packages/rust → dirsql-0.3.124}/docs/howto/persist.md +1 -1
  7. {dirsql-0.3.123/packages/python → dirsql-0.3.124}/docs/howto/react-to-changes.md +2 -2
  8. {dirsql-0.3.123/packages/rust → dirsql-0.3.124}/docs/howto/search-by-meaning.md +1 -1
  9. {dirsql-0.3.123/packages/python → dirsql-0.3.124}/docs/reference/cli.md +35 -14
  10. {dirsql-0.3.123/packages/python → dirsql-0.3.124}/docs/reference/config.md +1 -1
  11. {dirsql-0.3.123/packages/rust → dirsql-0.3.124}/docs/reference/http-api.md +1 -1
  12. {dirsql-0.3.123/packages/rust → dirsql-0.3.124}/docs/reference/sdk.md +1 -1
  13. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/Cargo.toml +1 -1
  14. {dirsql-0.3.123 → dirsql-0.3.124/packages/python}/README.md +1 -1
  15. {dirsql-0.3.123 → dirsql-0.3.124/packages/python}/docs/getting-started.md +4 -4
  16. {dirsql-0.3.123/packages/rust → dirsql-0.3.124/packages/python}/docs/howto/load-extension.md +1 -1
  17. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/howto/persist.md +1 -1
  18. {dirsql-0.3.123/packages/rust → dirsql-0.3.124/packages/python}/docs/howto/react-to-changes.md +2 -2
  19. {dirsql-0.3.123 → dirsql-0.3.124/packages/python}/docs/howto/search-by-meaning.md +1 -1
  20. {dirsql-0.3.123/packages/rust → dirsql-0.3.124/packages/python}/docs/reference/cli.md +35 -14
  21. {dirsql-0.3.123 → dirsql-0.3.124/packages/python}/docs/reference/config.md +1 -1
  22. {dirsql-0.3.123 → dirsql-0.3.124/packages/python}/docs/reference/http-api.md +1 -1
  23. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/reference/sdk.md +1 -1
  24. dirsql-0.3.124/packages/python/e2e-attestations/feat-662-query-default-cli.json +7 -0
  25. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/README.md +2 -2
  26. dirsql-0.3.124/packages/rust/changelog.d/2026-07-23-query-default-cli.md +1 -0
  27. {dirsql-0.3.123/packages/python → dirsql-0.3.124/packages/rust}/docs/getting-started.md +4 -4
  28. {dirsql-0.3.123 → dirsql-0.3.124/packages/rust}/docs/howto/load-extension.md +1 -1
  29. {dirsql-0.3.123 → dirsql-0.3.124/packages/rust}/docs/howto/persist.md +1 -1
  30. {dirsql-0.3.123 → dirsql-0.3.124/packages/rust}/docs/howto/react-to-changes.md +2 -2
  31. {dirsql-0.3.123/packages/python → dirsql-0.3.124/packages/rust}/docs/howto/search-by-meaning.md +1 -1
  32. {dirsql-0.3.123 → dirsql-0.3.124/packages/rust}/docs/reference/cli.md +35 -14
  33. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/reference/config.md +1 -1
  34. {dirsql-0.3.123/packages/python → dirsql-0.3.124/packages/rust}/docs/reference/http-api.md +1 -1
  35. {dirsql-0.3.123 → dirsql-0.3.124/packages/rust}/docs/reference/sdk.md +1 -1
  36. dirsql-0.3.124/packages/rust/migrations.d/2026-07-23-query-default-cli.md +55 -0
  37. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/bin/dirsql.rs +173 -37
  38. {dirsql-0.3.123 → dirsql-0.3.124}/Cargo.toml +0 -0
  39. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/__init__.py +0 -0
  40. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/_async.py +0 -0
  41. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/_dirsql.pyi +0 -0
  42. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/__init__.py +0 -0
  43. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/binary_path.py +0 -0
  44. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/discover_plugins/__init__.py +0 -0
  45. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/discover_plugins/discovered_fragments.py +0 -0
  46. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/discover_plugins/discovery_disabled.py +0 -0
  47. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/discover_plugins/fragment_path.py +0 -0
  48. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/discover_plugins/user_passed_config.py +0 -0
  49. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/discover_plugins/with_discovered_plugins.py +0 -0
  50. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/is_windows.py +0 -0
  51. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/main.py +0 -0
  52. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/cli/resolve_config_extensions.py +0 -0
  53. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/py.typed +0 -0
  54. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/resolve_config_extensions.py +0 -0
  55. {dirsql-0.3.123 → dirsql-0.3.124}/dirsql/resolve_extension.py +0 -0
  56. {dirsql-0.3.123 → dirsql-0.3.124}/docs/.claude/CLAUDE.md +0 -0
  57. {dirsql-0.3.123 → dirsql-0.3.124}/docs/.vitepress/config.ts +0 -0
  58. {dirsql-0.3.123 → dirsql-0.3.124}/docs/.vitepress/theme/index.ts +0 -0
  59. {dirsql-0.3.123 → dirsql-0.3.124}/docs/.vitepress/theme/lang.ts +0 -0
  60. {dirsql-0.3.123 → dirsql-0.3.124}/docs/AGENTS.md +0 -0
  61. {dirsql-0.3.123 → dirsql-0.3.124}/docs/explanation.md +0 -0
  62. {dirsql-0.3.123 → dirsql-0.3.124}/docs/howto/columns-from-paths.md +0 -0
  63. {dirsql-0.3.123 → dirsql-0.3.124}/docs/howto/define-tables.md +0 -0
  64. {dirsql-0.3.123 → dirsql-0.3.124}/docs/howto/embed.md +0 -0
  65. {dirsql-0.3.123 → dirsql-0.3.124}/docs/howto/extract-from-contents.md +0 -0
  66. {dirsql-0.3.123 → dirsql-0.3.124}/docs/howto/parse-files-into-columns.md +0 -0
  67. {dirsql-0.3.123 → dirsql-0.3.124}/docs/howto/query-without-config.md +0 -0
  68. {dirsql-0.3.123 → dirsql-0.3.124}/docs/howto/skip-files.md +0 -0
  69. {dirsql-0.3.123 → dirsql-0.3.124}/docs/howto/write-a-plugin.md +0 -0
  70. {dirsql-0.3.123 → dirsql-0.3.124}/docs/index.md +0 -0
  71. {dirsql-0.3.123 → dirsql-0.3.124}/docs/migrations.md +0 -0
  72. {dirsql-0.3.123 → dirsql-0.3.124}/docs/package.json +0 -0
  73. {dirsql-0.3.123 → dirsql-0.3.124}/docs/pnpm-lock.yaml +0 -0
  74. {dirsql-0.3.123 → dirsql-0.3.124}/docs/pnpm-workspace.yaml +0 -0
  75. {dirsql-0.3.123 → dirsql-0.3.124}/docs/reference/columns.md +0 -0
  76. {dirsql-0.3.123 → dirsql-0.3.124}/docs/reference/hooks.md +0 -0
  77. {dirsql-0.3.123 → dirsql-0.3.124}/docs/reference/path-tables.md +0 -0
  78. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/CHANGELOG.md +0 -0
  79. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/MIGRATIONS.md +0 -0
  80. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/changelog.d/2026-07-13-drop-cwd-config-auto-detect.md +0 -0
  81. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/changelog.d/2026-07-13-plugin-discovery.md +0 -0
  82. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/changelog.d/2026-07-13-rename-extract-to-on-file.md +0 -0
  83. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/changelog.d/2026-07-13-repeatable-config.md +0 -0
  84. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/changelog.d/2026-07-13-sdk-default-baked-in-config.md +0 -0
  85. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/changelog.d/2026-07-20-drop-implicit-files-table.md +0 -0
  86. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/changelog.d/2026-07-21-remove-glob-captures.md +0 -0
  87. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/changelog.d/README.md +0 -0
  88. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/conftest.py +0 -0
  89. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/.claude/CLAUDE.md +0 -0
  90. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/.vitepress/config.ts +0 -0
  91. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/.vitepress/theme/index.ts +0 -0
  92. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/.vitepress/theme/lang.ts +0 -0
  93. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/AGENTS.md +0 -0
  94. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/explanation.md +0 -0
  95. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/howto/columns-from-paths.md +0 -0
  96. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/howto/define-tables.md +0 -0
  97. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/howto/embed.md +0 -0
  98. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/howto/extract-from-contents.md +0 -0
  99. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/howto/parse-files-into-columns.md +0 -0
  100. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/howto/query-without-config.md +0 -0
  101. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/howto/skip-files.md +0 -0
  102. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/howto/write-a-plugin.md +0 -0
  103. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/index.md +0 -0
  104. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/migrations.md +0 -0
  105. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/package.json +0 -0
  106. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/pnpm-lock.yaml +0 -0
  107. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/pnpm-workspace.yaml +0 -0
  108. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/reference/columns.md +0 -0
  109. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/reference/hooks.md +0 -0
  110. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/docs/reference/path-tables.md +0 -0
  111. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/e2e-attestations/feat-634-prep-python-selfemit.json +0 -0
  112. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/migrations.d/2026-07-13-drop-cwd-config-auto-detect.md +0 -0
  113. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/migrations.d/2026-07-13-rename-extract-to-on-file.md +0 -0
  114. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/migrations.d/2026-07-13-sdk-default-baked-in-config.md +0 -0
  115. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/migrations.d/2026-07-20-drop-implicit-files-table.md +0 -0
  116. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/migrations.d/2026-07-21-remove-glob-captures.md +0 -0
  117. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/migrations.d/README.md +0 -0
  118. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/src/lib.rs +0 -0
  119. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/tests/__init__.py +0 -0
  120. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/tests/conftest.py +0 -0
  121. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/tests/e2e/__init__.py +0 -0
  122. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/tests/e2e/fixtures/dirsql_plugin_fixture/__init__.py +0 -0
  123. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/tests/e2e/fixtures/dirsql_plugin_fixture/dirsql.toml +0 -0
  124. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/tests/integration/__init__.py +0 -0
  125. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/tests/integration/binding/__init__.py +0 -0
  126. {dirsql-0.3.123 → dirsql-0.3.124}/packages/python/tests/integration/hermetic/__init__.py +0 -0
  127. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/CHANGELOG.md +0 -0
  128. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/Cargo.toml +0 -0
  129. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/MIGRATIONS.md +0 -0
  130. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/benches/db_bench.rs +0 -0
  131. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/benches/differ_bench.rs +0 -0
  132. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/benches/matcher_bench.rs +0 -0
  133. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/benches/scanner_bench.rs +0 -0
  134. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-batch-ingest-transaction.md +0 -0
  135. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-chained-pre-post-query-hooks.md +0 -0
  136. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-drop-cwd-config-auto-detect.md +0 -0
  137. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-fan-out-file-table-matching.md +0 -0
  138. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-persist-wal.md +0 -0
  139. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-rename-extract-to-on-file.md +0 -0
  140. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-repeatable-builder-config.md +0 -0
  141. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-repeatable-cli-config.md +0 -0
  142. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-sdk-default-baked-in-config.md +0 -0
  143. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-13-subcommand-local-config-flags.md +0 -0
  144. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-19-path-table-query-fallback.md +0 -0
  145. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-19-path-table-vtab.md +0 -0
  146. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-20-drop-implicit-files-table.md +0 -0
  147. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-20-path-table-glob-semantics.md +0 -0
  148. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-20-schema-inference.md +0 -0
  149. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-21-on-file-flag.md +0 -0
  150. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-21-remove-glob-captures.md +0 -0
  151. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/2026-07-23-init-escalation-example.md +0 -0
  152. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/changelog.d/README.md +0 -0
  153. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/explanation.md +0 -0
  154. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/howto/columns-from-paths.md +0 -0
  155. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/howto/define-tables.md +0 -0
  156. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/howto/embed.md +0 -0
  157. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/howto/extract-from-contents.md +0 -0
  158. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/howto/parse-files-into-columns.md +0 -0
  159. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/howto/query-without-config.md +0 -0
  160. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/howto/skip-files.md +0 -0
  161. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/howto/write-a-plugin.md +0 -0
  162. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/index.md +0 -0
  163. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/migrations.md +0 -0
  164. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/reference/columns.md +0 -0
  165. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/reference/hooks.md +0 -0
  166. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/docs/reference/path-tables.md +0 -0
  167. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-13-drop-cwd-config-auto-detect.md +0 -0
  168. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-13-fan-out-file-table-matching.md +0 -0
  169. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-13-persist-wal.md +0 -0
  170. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-13-rename-extract-to-on-file.md +0 -0
  171. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-13-sdk-default-baked-in-config.md +0 -0
  172. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-13-subcommand-local-config-flags.md +0 -0
  173. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-20-drop-implicit-files-table.md +0 -0
  174. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-20-path-table-glob-semantics.md +0 -0
  175. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-21-remove-glob-captures.md +0 -0
  176. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/2026-07-23-init-escalation-example.md +0 -0
  177. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/migrations.d/README.md +0 -0
  178. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/cli/execute.rs +0 -0
  179. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/cli/init.rs +0 -0
  180. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/cli/mod.rs +0 -0
  181. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/cli/router.rs +0 -0
  182. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/cli/serialize.rs +0 -0
  183. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/cli/server.rs +0 -0
  184. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/command.rs +0 -0
  185. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/config.rs +0 -0
  186. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/db.rs +0 -0
  187. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/default_config.toml +0 -0
  188. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/differ.rs +0 -0
  189. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/infer.rs +0 -0
  190. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/lib.rs +0 -0
  191. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/matcher.rs +0 -0
  192. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/parsed_vtab.rs +0 -0
  193. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/path_table.rs +0 -0
  194. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/persist.rs +0 -0
  195. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/scanner.rs +0 -0
  196. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/vtab.rs +0 -0
  197. {dirsql-0.3.123 → dirsql-0.3.124}/packages/rust/src/watcher.rs +0 -0
  198. {dirsql-0.3.123 → dirsql-0.3.124}/pyproject.toml +0 -0
@@ -500,7 +500,7 @@ dependencies = [
500
500
 
501
501
  [[package]]
502
502
  name = "dirsql-py-ext"
503
- version = "0.3.123"
503
+ version = "0.3.124"
504
504
  dependencies = [
505
505
  "dirsql",
506
506
  "pyo3",
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dirsql
3
- Version: 0.3.123
3
+ Version: 0.3.124
4
4
  Summary: Ephemeral SQL index over a local directory
5
5
  Keywords: sql,filesystem,directory,sqlite,index
6
6
  Author: Kevin Scott
@@ -126,7 +126,7 @@ Each event has `.action` (`"insert"`, `"update"`, `"delete"`, or `"error"`), `.t
126
126
 
127
127
  ## CLI
128
128
 
129
- `pip install dirsql` also installs a `dirsql` console script that runs an HTTP server exposing the SDK over HTTP: `POST /query` for SQL and `GET /events` for a Server-Sent Events change stream. Run `dirsql` (or `uvx dirsql`) to start it. See the [CLI reference](https://thekevinscott.github.io/dirsql/reference/cli).
129
+ `pip install dirsql` also installs a `dirsql` console script. `dirsql "<sql>"` (or `uvx dirsql "<sql>"`) runs one query and prints the rows as JSON — the default. `dirsql server` starts an HTTP server exposing the SDK over HTTP: `POST /query` for SQL and `GET /events` for a Server-Sent Events change stream. See the [CLI reference](https://thekevinscott.github.io/dirsql/reference/cli).
130
130
 
131
131
  ## License
132
132
 
@@ -116,7 +116,7 @@ Each event has `.action` (`"insert"`, `"update"`, `"delete"`, or `"error"`), `.t
116
116
 
117
117
  ## CLI
118
118
 
119
- `pip install dirsql` also installs a `dirsql` console script that runs an HTTP server exposing the SDK over HTTP: `POST /query` for SQL and `GET /events` for a Server-Sent Events change stream. Run `dirsql` (or `uvx dirsql`) to start it. See the [CLI reference](https://thekevinscott.github.io/dirsql/reference/cli).
119
+ `pip install dirsql` also installs a `dirsql` console script. `dirsql "<sql>"` (or `uvx dirsql "<sql>"`) runs one query and prints the rows as JSON — the default. `dirsql server` starts an HTTP server exposing the SDK over HTTP: `POST /query` for SQL and `GET /events` for a Server-Sent Events change stream. See the [CLI reference](https://thekevinscott.github.io/dirsql/reference/cli).
120
120
 
121
121
  ## License
122
122
 
@@ -68,11 +68,11 @@ this directory anyway — from inside `my-notes`, run one command:
68
68
  ::: code-group
69
69
 
70
70
  ```bash [npm]
71
- npx dirsql query "SELECT COUNT(*) AS files FROM './'"
71
+ npx dirsql "SELECT COUNT(*) AS files FROM './'"
72
72
  ```
73
73
 
74
74
  ```bash [PyPI]
75
- uvx dirsql query "SELECT COUNT(*) AS files FROM './'"
75
+ uvx dirsql "SELECT COUNT(*) AS files FROM './'"
76
76
  ```
77
77
 
78
78
  :::
@@ -168,11 +168,11 @@ pass it explicitly with `-c`, **after** the SQL:
168
168
  ::: code-group
169
169
 
170
170
  ```bash [npm]
171
- npx dirsql query "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
171
+ npx dirsql "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
172
172
  ```
173
173
 
174
174
  ```bash [PyPI]
175
- uvx dirsql query "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
175
+ uvx dirsql "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
176
176
  ```
177
177
 
178
178
  :::
@@ -53,7 +53,7 @@ entrypoint = "sqlite3_vec_init"
53
53
  ```
54
54
 
55
55
  ```bash
56
- uvx --with sqlite-vec dirsql -c ./.dirsql.toml
56
+ uvx --with sqlite-vec dirsql server -c ./.dirsql.toml
57
57
  ```
58
58
 
59
59
  **Node (`npx dirsql`, TypeScript SDK).** Use the *npm package name* — but
@@ -1,7 +1,7 @@
1
1
  # Keep the index across restarts
2
2
 
3
3
  By default the database is ephemeral: rebuilt from your files on every
4
- startup and discarded on exit. The [`--persist [PATH]`](../reference/cli.md#server-mode)
4
+ startup and discarded on exit. The [`--persist [PATH]`](../reference/cli.md#dirsql-server)
5
5
  flag keeps the SQLite index on disk instead, so a restart only re-parses
6
6
  files that actually changed — the difference between seconds and
7
7
  milliseconds on large trees, and between re-running and skipping expensive
@@ -18,8 +18,8 @@ glob = "**/*"
18
18
 
19
19
  ## 1. Open the stream
20
20
 
21
- With the server running (`npx dirsql -c ./.dirsql.toml` /
22
- `uvx dirsql -c ./.dirsql.toml`), subscribe from another terminal:
21
+ With the server running (`npx dirsql server -c ./.dirsql.toml` /
22
+ `uvx dirsql server -c ./.dirsql.toml`), subscribe from another terminal:
23
23
 
24
24
  ```bash
25
25
  curl -N http://localhost:7117/events
@@ -10,7 +10,7 @@ embed each question at query time.
10
10
  ::: tip Just want it working?
11
11
  [`dirsql-plugin-embeddings`](https://pypi.org/project/dirsql-plugin-embeddings/)
12
12
  packages exactly what this guide builds, ready to install:
13
- `uvx --with dirsql-plugin-embeddings dirsql`. Keep reading to see how it's
13
+ `uvx --with dirsql-plugin-embeddings dirsql server`. Keep reading to see how it's
14
14
  built — the same three pieces, from scratch.
15
15
  :::
16
16
 
@@ -1,39 +1,56 @@
1
1
  # CLI
2
2
 
3
- The `dirsql` binary has three modes:
3
+ Query is the default: `dirsql "<sql>"` runs one query and prints JSON rows.
4
+ The `dirsql` binary has these modes:
4
5
 
5
6
  | Invocation | Behavior |
6
7
  |---|---|
7
- | `dirsql` (no subcommand) | Start a long-lived HTTP server exposing a SQL view of a directory. See [HTTP API](./http-api.md). |
8
- | `dirsql query "<sql>"` | Query the file system as JSON |
9
- | `dirsql init` | Generate a `.dirsql.toml` |
8
+ | `dirsql "<sql>"` | Run one query over the directory and print the rows as JSON. The default; identical to `dirsql query "<sql>"`. |
9
+ | `dirsql query "<sql>"` | Explicit synonym for the default one-shot query. |
10
+ | `dirsql server` | Start a long-lived HTTP server exposing a SQL view of a directory. See [HTTP API](./http-api.md). |
11
+ | `dirsql init` | Generate a `.dirsql.toml`. |
12
+
13
+ Bare `dirsql` with no SQL is a usage error pointing at `dirsql server` — it
14
+ does **not** start the server.
10
15
 
11
16
  ## Installation
12
17
 
13
18
  ::: code-group
14
19
 
15
20
  ```bash [npm]
16
- npx dirsql
21
+ npx dirsql "SELECT * FROM './'"
17
22
  ```
18
23
 
19
24
  ```bash [PyPI]
20
- uvx dirsql
25
+ uvx dirsql "SELECT * FROM './'"
21
26
  ```
22
27
 
23
28
  ```bash [Cargo]
24
29
  # The `cli` feature is opt-in; this installs the binary only.
25
30
  cargo install dirsql --features cli
26
- dirsql
31
+ dirsql "SELECT * FROM './'"
27
32
  ```
28
33
 
29
34
  :::
30
35
 
31
36
  The npm launcher requires **Node ≥ 20.11**.
32
37
 
33
- ## Server mode
38
+ ## Default query mode
34
39
 
35
40
  ```bash
36
- dirsql
41
+ # No -c: query the filesystem with a path-table.
42
+ dirsql "SELECT basename, size FROM './' ORDER BY size DESC LIMIT 5"
43
+ # [{"basename":"model.bin","size":104857600}, …]
44
+ ```
45
+
46
+ `dirsql "<sql>"` is exactly [`dirsql query "<sql>"`](#dirsql-query) — same
47
+ pipeline, same flags, same output. See that section for config discovery,
48
+ `--persist`, `--on-file`, hooks, and exit codes.
49
+
50
+ ## `dirsql server`
51
+
52
+ ```bash
53
+ dirsql server
37
54
  # Running at localhost:7117
38
55
  ```
39
56
 
@@ -43,12 +60,15 @@ requests, closes open `/events` streams, and exits.
43
60
 
44
61
  ### Flags
45
62
 
63
+ Config flags are subcommand-local: pass them after `server`
64
+ (`dirsql server -c <cfg>`).
65
+
46
66
  | Flag | Default | Description |
47
67
  |---|---|---|
48
- | `-c, --config <path>` | none | Path to a [config file](./config.md). **Repeatable** (`-c a -c b`): the configs load and merge in argv order — see [Composing multiple configs](./config.md#composing-multiple-configs). The index is always rooted at the **invocation directory** (the current working directory), regardless of where a config lives — so `--config /elsewhere/.dirsql.toml` still indexes the directory you ran `dirsql` from. With none given, **no named tables are defined** — query the filesystem with a [path-table](./path-tables.md) (`FROM './'`). A `./.dirsql.toml` on disk is **not** auto-loaded; pass it explicitly. A `-c` naming a file that does not exist is an [error](#degraded-mode). |
68
+ | `-c, --config <path>` | none | Path to a [config file](./config.md). **Repeatable** (`-c a -c b`): the configs load and merge in argv order — see [Composing multiple configs](./config.md#composing-multiple-configs). The index is always rooted at the **invocation directory** (the current working directory), regardless of where a config lives — so `--config /elsewhere/.dirsql.toml` still indexes the directory you ran `dirsql server` from. With none given, **no named tables are defined** — query the filesystem with a [path-table](./path-tables.md) (`FROM './'`). A `./.dirsql.toml` on disk is **not** auto-loaded; pass it explicitly. A `-c` naming a file that does not exist is an [error](#degraded-mode). |
49
69
  | `--host <addr>` | `localhost` | Bind address. |
50
70
  | `--port <n>` | `7117` | TCP port to bind. |
51
- | `--persist [<path>]` | off | Keep the SQLite index on disk between runs so a restart only re-parses files that actually changed. Bare `--persist` caches at `<root>/.dirsql/cache.db`; `--persist <path>` caches at `<path>`. Off by default (the index is ephemeral). Also available on [`dirsql query`](#dirsql-query), passed after the subcommand. See [Keep the index across restarts](../howto/persist.md). |
71
+ | `--persist [<path>]` | off | Keep the SQLite index on disk between runs so a restart only re-parses files that actually changed. Bare `--persist` caches at `<root>/.dirsql/cache.db`; `--persist <path>` caches at `<path>`. Off by default (the index is ephemeral). Also available on [`dirsql query`](#dirsql-query). See [Keep the index across restarts](../howto/persist.md). |
52
72
  | `--extension <path>` | none | Load a SQLite extension by literal path, overriding the config's `[[dirsql.extension]]` entries. Repeatable. Format: `<path>` or `<path>::<entrypoint>`. Internal plumbing for the pip/npm launchers, which resolve package-name extensions and pass the resolved paths here — not intended for direct use. When any `--extension` is present, the config file's own extension entries are not loaded. |
53
73
  | `--version` | | Print the version and exit. |
54
74
  | `--help` | | Print usage and exit. |
@@ -124,8 +144,9 @@ dirsql query "SELECT COUNT(*) AS n FROM posts" -c ./.dirsql.toml | jq '.[0].n'
124
144
  Pass `-c`/`--config`, `--persist`, and `--extension` **after** `query`
125
145
  (`dirsql query "<sql>" -c <cfg>`). A config flag placed *before* the subcommand
126
146
  is a hard error — `error: the subcommand 'query' cannot be used with
127
- '--config <CONFIG>'` — never silently dropped. (In server mode, with no
128
- subcommand, the same flags are passed directly: `dirsql -c <cfg>`.)
147
+ '--config <CONFIG>'` — never silently dropped. (The default mode without the
148
+ `query` keyword takes the same flags after the SQL: `dirsql "<sql>" -c <cfg>`;
149
+ for the server they follow the subcommand: `dirsql server -c <cfg>`.)
129
150
  :::
130
151
 
131
152
  The subcommand builds the index, runs the SQL, prints the result rows as a
@@ -199,7 +220,7 @@ The output does **not** auto-load. Once you've tweaked it, pass it explicitly
199
220
  to run against it:
200
221
 
201
222
  ```bash
202
- dirsql -c ./.dirsql.toml
223
+ dirsql "SELECT * FROM files" -c ./.dirsql.toml
203
224
  ```
204
225
 
205
226
  ### Flags
@@ -40,7 +40,7 @@ hook-timeout = 300
40
40
  ```
41
41
 
42
42
  Persistence is not a config key. Keep the SQLite index on disk between runs
43
- with the [`--persist [PATH]` CLI flag](./cli.md#server-mode) — a machine-local
43
+ with the [`--persist [PATH]` CLI flag](./cli.md#dirsql-server) — a machine-local
44
44
  operational choice that belongs to the runner, not to shareable config.
45
45
 
46
46
  ## `[[dirsql.extension]]`
@@ -1,6 +1,6 @@
1
1
  # HTTP API
2
2
 
3
- The [`dirsql` server](./cli.md#server-mode) (default `localhost:7117`)
3
+ The [`dirsql` server](./cli.md#dirsql-server) (default `localhost:7117`)
4
4
  exposes two endpoints: `POST /query` and `GET /events`.
5
5
 
6
6
  ## `POST /query`
@@ -130,7 +130,7 @@ shortcut was removed in #603 — use
130
130
  ephemeral, rebuilt every startup). The cache lives at
131
131
  `<root>/.dirsql/cache.db` by default; on restart, only files whose stat
132
132
  changed are re-parsed. (The CLI exposes the same switch as the
133
- [`--persist [PATH]`](./cli.md#server-mode) flag; it is not a config key.)
133
+ [`--persist [PATH]`](./cli.md#dirsql-server) flag; it is not a config key.)
134
134
  - `persist_path` / `persistPath` — Override the cache location. Ignored when
135
135
  persistence is off. Constructor values are used as given. In Rust these two
136
136
  parameters collapse into a single builder method: `.persist(None)` enables
@@ -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.123"
7
+ version = "0.3.124"
8
8
  # abi3 note: the `abi3-py311` pyo3 feature (below) builds ONE stable-ABI
9
9
  # `cp311-abi3` wheel per platform that loads on every CPython >= 3.11
10
10
  # (matching `pyproject.toml`'s `requires-python = ">=3.11"`), instead of
@@ -116,7 +116,7 @@ Each event has `.action` (`"insert"`, `"update"`, `"delete"`, or `"error"`), `.t
116
116
 
117
117
  ## CLI
118
118
 
119
- `pip install dirsql` also installs a `dirsql` console script that runs an HTTP server exposing the SDK over HTTP: `POST /query` for SQL and `GET /events` for a Server-Sent Events change stream. Run `dirsql` (or `uvx dirsql`) to start it. See the [CLI reference](https://thekevinscott.github.io/dirsql/reference/cli).
119
+ `pip install dirsql` also installs a `dirsql` console script. `dirsql "<sql>"` (or `uvx dirsql "<sql>"`) runs one query and prints the rows as JSON — the default. `dirsql server` starts an HTTP server exposing the SDK over HTTP: `POST /query` for SQL and `GET /events` for a Server-Sent Events change stream. See the [CLI reference](https://thekevinscott.github.io/dirsql/reference/cli).
120
120
 
121
121
  ## License
122
122
 
@@ -68,11 +68,11 @@ this directory anyway — from inside `my-notes`, run one command:
68
68
  ::: code-group
69
69
 
70
70
  ```bash [npm]
71
- npx dirsql query "SELECT COUNT(*) AS files FROM './'"
71
+ npx dirsql "SELECT COUNT(*) AS files FROM './'"
72
72
  ```
73
73
 
74
74
  ```bash [PyPI]
75
- uvx dirsql query "SELECT COUNT(*) AS files FROM './'"
75
+ uvx dirsql "SELECT COUNT(*) AS files FROM './'"
76
76
  ```
77
77
 
78
78
  :::
@@ -168,11 +168,11 @@ pass it explicitly with `-c`, **after** the SQL:
168
168
  ::: code-group
169
169
 
170
170
  ```bash [npm]
171
- npx dirsql query "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
171
+ npx dirsql "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
172
172
  ```
173
173
 
174
174
  ```bash [PyPI]
175
- uvx dirsql query "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
175
+ uvx dirsql "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
176
176
  ```
177
177
 
178
178
  :::
@@ -53,7 +53,7 @@ entrypoint = "sqlite3_vec_init"
53
53
  ```
54
54
 
55
55
  ```bash
56
- uvx --with sqlite-vec dirsql -c ./.dirsql.toml
56
+ uvx --with sqlite-vec dirsql server -c ./.dirsql.toml
57
57
  ```
58
58
 
59
59
  **Node (`npx dirsql`, TypeScript SDK).** Use the *npm package name* — but
@@ -1,7 +1,7 @@
1
1
  # Keep the index across restarts
2
2
 
3
3
  By default the database is ephemeral: rebuilt from your files on every
4
- startup and discarded on exit. The [`--persist [PATH]`](../reference/cli.md#server-mode)
4
+ startup and discarded on exit. The [`--persist [PATH]`](../reference/cli.md#dirsql-server)
5
5
  flag keeps the SQLite index on disk instead, so a restart only re-parses
6
6
  files that actually changed — the difference between seconds and
7
7
  milliseconds on large trees, and between re-running and skipping expensive
@@ -18,8 +18,8 @@ glob = "**/*"
18
18
 
19
19
  ## 1. Open the stream
20
20
 
21
- With the server running (`npx dirsql -c ./.dirsql.toml` /
22
- `uvx dirsql -c ./.dirsql.toml`), subscribe from another terminal:
21
+ With the server running (`npx dirsql server -c ./.dirsql.toml` /
22
+ `uvx dirsql server -c ./.dirsql.toml`), subscribe from another terminal:
23
23
 
24
24
  ```bash
25
25
  curl -N http://localhost:7117/events
@@ -10,7 +10,7 @@ embed each question at query time.
10
10
  ::: tip Just want it working?
11
11
  [`dirsql-plugin-embeddings`](https://pypi.org/project/dirsql-plugin-embeddings/)
12
12
  packages exactly what this guide builds, ready to install:
13
- `uvx --with dirsql-plugin-embeddings dirsql`. Keep reading to see how it's
13
+ `uvx --with dirsql-plugin-embeddings dirsql server`. Keep reading to see how it's
14
14
  built — the same three pieces, from scratch.
15
15
  :::
16
16
 
@@ -1,39 +1,56 @@
1
1
  # CLI
2
2
 
3
- The `dirsql` binary has three modes:
3
+ Query is the default: `dirsql "<sql>"` runs one query and prints JSON rows.
4
+ The `dirsql` binary has these modes:
4
5
 
5
6
  | Invocation | Behavior |
6
7
  |---|---|
7
- | `dirsql` (no subcommand) | Start a long-lived HTTP server exposing a SQL view of a directory. See [HTTP API](./http-api.md). |
8
- | `dirsql query "<sql>"` | Query the file system as JSON |
9
- | `dirsql init` | Generate a `.dirsql.toml` |
8
+ | `dirsql "<sql>"` | Run one query over the directory and print the rows as JSON. The default; identical to `dirsql query "<sql>"`. |
9
+ | `dirsql query "<sql>"` | Explicit synonym for the default one-shot query. |
10
+ | `dirsql server` | Start a long-lived HTTP server exposing a SQL view of a directory. See [HTTP API](./http-api.md). |
11
+ | `dirsql init` | Generate a `.dirsql.toml`. |
12
+
13
+ Bare `dirsql` with no SQL is a usage error pointing at `dirsql server` — it
14
+ does **not** start the server.
10
15
 
11
16
  ## Installation
12
17
 
13
18
  ::: code-group
14
19
 
15
20
  ```bash [npm]
16
- npx dirsql
21
+ npx dirsql "SELECT * FROM './'"
17
22
  ```
18
23
 
19
24
  ```bash [PyPI]
20
- uvx dirsql
25
+ uvx dirsql "SELECT * FROM './'"
21
26
  ```
22
27
 
23
28
  ```bash [Cargo]
24
29
  # The `cli` feature is opt-in; this installs the binary only.
25
30
  cargo install dirsql --features cli
26
- dirsql
31
+ dirsql "SELECT * FROM './'"
27
32
  ```
28
33
 
29
34
  :::
30
35
 
31
36
  The npm launcher requires **Node ≥ 20.11**.
32
37
 
33
- ## Server mode
38
+ ## Default query mode
34
39
 
35
40
  ```bash
36
- dirsql
41
+ # No -c: query the filesystem with a path-table.
42
+ dirsql "SELECT basename, size FROM './' ORDER BY size DESC LIMIT 5"
43
+ # [{"basename":"model.bin","size":104857600}, …]
44
+ ```
45
+
46
+ `dirsql "<sql>"` is exactly [`dirsql query "<sql>"`](#dirsql-query) — same
47
+ pipeline, same flags, same output. See that section for config discovery,
48
+ `--persist`, `--on-file`, hooks, and exit codes.
49
+
50
+ ## `dirsql server`
51
+
52
+ ```bash
53
+ dirsql server
37
54
  # Running at localhost:7117
38
55
  ```
39
56
 
@@ -43,12 +60,15 @@ requests, closes open `/events` streams, and exits.
43
60
 
44
61
  ### Flags
45
62
 
63
+ Config flags are subcommand-local: pass them after `server`
64
+ (`dirsql server -c <cfg>`).
65
+
46
66
  | Flag | Default | Description |
47
67
  |---|---|---|
48
- | `-c, --config <path>` | none | Path to a [config file](./config.md). **Repeatable** (`-c a -c b`): the configs load and merge in argv order — see [Composing multiple configs](./config.md#composing-multiple-configs). The index is always rooted at the **invocation directory** (the current working directory), regardless of where a config lives — so `--config /elsewhere/.dirsql.toml` still indexes the directory you ran `dirsql` from. With none given, **no named tables are defined** — query the filesystem with a [path-table](./path-tables.md) (`FROM './'`). A `./.dirsql.toml` on disk is **not** auto-loaded; pass it explicitly. A `-c` naming a file that does not exist is an [error](#degraded-mode). |
68
+ | `-c, --config <path>` | none | Path to a [config file](./config.md). **Repeatable** (`-c a -c b`): the configs load and merge in argv order — see [Composing multiple configs](./config.md#composing-multiple-configs). The index is always rooted at the **invocation directory** (the current working directory), regardless of where a config lives — so `--config /elsewhere/.dirsql.toml` still indexes the directory you ran `dirsql server` from. With none given, **no named tables are defined** — query the filesystem with a [path-table](./path-tables.md) (`FROM './'`). A `./.dirsql.toml` on disk is **not** auto-loaded; pass it explicitly. A `-c` naming a file that does not exist is an [error](#degraded-mode). |
49
69
  | `--host <addr>` | `localhost` | Bind address. |
50
70
  | `--port <n>` | `7117` | TCP port to bind. |
51
- | `--persist [<path>]` | off | Keep the SQLite index on disk between runs so a restart only re-parses files that actually changed. Bare `--persist` caches at `<root>/.dirsql/cache.db`; `--persist <path>` caches at `<path>`. Off by default (the index is ephemeral). Also available on [`dirsql query`](#dirsql-query), passed after the subcommand. See [Keep the index across restarts](../howto/persist.md). |
71
+ | `--persist [<path>]` | off | Keep the SQLite index on disk between runs so a restart only re-parses files that actually changed. Bare `--persist` caches at `<root>/.dirsql/cache.db`; `--persist <path>` caches at `<path>`. Off by default (the index is ephemeral). Also available on [`dirsql query`](#dirsql-query). See [Keep the index across restarts](../howto/persist.md). |
52
72
  | `--extension <path>` | none | Load a SQLite extension by literal path, overriding the config's `[[dirsql.extension]]` entries. Repeatable. Format: `<path>` or `<path>::<entrypoint>`. Internal plumbing for the pip/npm launchers, which resolve package-name extensions and pass the resolved paths here — not intended for direct use. When any `--extension` is present, the config file's own extension entries are not loaded. |
53
73
  | `--version` | | Print the version and exit. |
54
74
  | `--help` | | Print usage and exit. |
@@ -124,8 +144,9 @@ dirsql query "SELECT COUNT(*) AS n FROM posts" -c ./.dirsql.toml | jq '.[0].n'
124
144
  Pass `-c`/`--config`, `--persist`, and `--extension` **after** `query`
125
145
  (`dirsql query "<sql>" -c <cfg>`). A config flag placed *before* the subcommand
126
146
  is a hard error — `error: the subcommand 'query' cannot be used with
127
- '--config <CONFIG>'` — never silently dropped. (In server mode, with no
128
- subcommand, the same flags are passed directly: `dirsql -c <cfg>`.)
147
+ '--config <CONFIG>'` — never silently dropped. (The default mode without the
148
+ `query` keyword takes the same flags after the SQL: `dirsql "<sql>" -c <cfg>`;
149
+ for the server they follow the subcommand: `dirsql server -c <cfg>`.)
129
150
  :::
130
151
 
131
152
  The subcommand builds the index, runs the SQL, prints the result rows as a
@@ -199,7 +220,7 @@ The output does **not** auto-load. Once you've tweaked it, pass it explicitly
199
220
  to run against it:
200
221
 
201
222
  ```bash
202
- dirsql -c ./.dirsql.toml
223
+ dirsql "SELECT * FROM files" -c ./.dirsql.toml
203
224
  ```
204
225
 
205
226
  ### Flags
@@ -40,7 +40,7 @@ hook-timeout = 300
40
40
  ```
41
41
 
42
42
  Persistence is not a config key. Keep the SQLite index on disk between runs
43
- with the [`--persist [PATH]` CLI flag](./cli.md#server-mode) — a machine-local
43
+ with the [`--persist [PATH]` CLI flag](./cli.md#dirsql-server) — a machine-local
44
44
  operational choice that belongs to the runner, not to shareable config.
45
45
 
46
46
  ## `[[dirsql.extension]]`
@@ -1,6 +1,6 @@
1
1
  # HTTP API
2
2
 
3
- The [`dirsql` server](./cli.md#server-mode) (default `localhost:7117`)
3
+ The [`dirsql` server](./cli.md#dirsql-server) (default `localhost:7117`)
4
4
  exposes two endpoints: `POST /query` and `GET /events`.
5
5
 
6
6
  ## `POST /query`
@@ -130,7 +130,7 @@ shortcut was removed in #603 — use
130
130
  ephemeral, rebuilt every startup). The cache lives at
131
131
  `<root>/.dirsql/cache.db` by default; on restart, only files whose stat
132
132
  changed are re-parsed. (The CLI exposes the same switch as the
133
- [`--persist [PATH]`](./cli.md#server-mode) flag; it is not a config key.)
133
+ [`--persist [PATH]`](./cli.md#dirsql-server) flag; it is not a config key.)
134
134
  - `persist_path` / `persistPath` — Override the cache location. Ignored when
135
135
  persistence is off. Constructor values are used as given. In Rust these two
136
136
  parameters collapse into a single builder method: `.persist(None)` enables
@@ -0,0 +1,7 @@
1
+ {
2
+ "command": "just test-e2e",
3
+ "ran_at": 1784897776,
4
+ "exit_code": 0,
5
+ "commit": "93084d576d3080073dc2e0af6c20201de7def162",
6
+ "branch": "feat/662-query-default-cli"
7
+ }
@@ -121,10 +121,10 @@ while let Some(event) = stream.next().await {
121
121
 
122
122
  ```bash
123
123
  cargo install dirsql --features cli
124
- dirsql
124
+ dirsql "SELECT * FROM './'"
125
125
  ```
126
126
 
127
- Running `dirsql` starts an HTTP server bound to `localhost:7117` that exposes the SDK over HTTP: `POST /query` for SQL and `GET /events` for a Server-Sent Events change stream. Override with `--host`, `--port`, `--config`. See the [CLI reference](https://thekevinscott.github.io/dirsql/reference/cli).
127
+ `dirsql "<sql>"` runs one query and prints the rows as JSON — the default. `dirsql server` starts an HTTP server bound to `localhost:7117` that exposes the SDK over HTTP: `POST /query` for SQL and `GET /events` for a Server-Sent Events change stream. Override the bind with `dirsql server --host`, `--port`, `--config`. See the [CLI reference](https://thekevinscott.github.io/dirsql/reference/cli).
128
128
 
129
129
  The `cli` feature is **opt-in** -- `cargo add dirsql` pulls no CLI dependencies. `cargo install dirsql` without `--features cli` silently installs nothing (`required-features` skips the bin target with no warning); always include the flag, or use `npx dirsql` / `uvx dirsql` for prebuilt binaries.
130
130
 
@@ -0,0 +1 @@
1
+ **Changed** Query is now the default CLI behavior. `dirsql "<sql>"` (no subcommand) runs one query and prints JSON rows — the epic headline `dirsql "SELECT * FROM './'"` works directly. The HTTP server moved behind a new `dirsql server` subcommand, and `--host`/`--port`/`--persist` are now `server`-local flags. `dirsql query "<sql>"` is retained as an explicit synonym and `dirsql init` is unchanged. **Breaking:** bare `dirsql` no longer starts a server; run `dirsql server`. Bare `dirsql` with no SQL now errors with a hint pointing at `dirsql server` (#662).
@@ -68,11 +68,11 @@ this directory anyway — from inside `my-notes`, run one command:
68
68
  ::: code-group
69
69
 
70
70
  ```bash [npm]
71
- npx dirsql query "SELECT COUNT(*) AS files FROM './'"
71
+ npx dirsql "SELECT COUNT(*) AS files FROM './'"
72
72
  ```
73
73
 
74
74
  ```bash [PyPI]
75
- uvx dirsql query "SELECT COUNT(*) AS files FROM './'"
75
+ uvx dirsql "SELECT COUNT(*) AS files FROM './'"
76
76
  ```
77
77
 
78
78
  :::
@@ -168,11 +168,11 @@ pass it explicitly with `-c`, **after** the SQL:
168
168
  ::: code-group
169
169
 
170
170
  ```bash [npm]
171
- npx dirsql query "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
171
+ npx dirsql "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
172
172
  ```
173
173
 
174
174
  ```bash [PyPI]
175
- uvx dirsql query "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
175
+ uvx dirsql "SELECT dir, basename, size FROM notes ORDER BY dir, basename" -c .dirsql.toml | jq
176
176
  ```
177
177
 
178
178
  :::
@@ -53,7 +53,7 @@ entrypoint = "sqlite3_vec_init"
53
53
  ```
54
54
 
55
55
  ```bash
56
- uvx --with sqlite-vec dirsql -c ./.dirsql.toml
56
+ uvx --with sqlite-vec dirsql server -c ./.dirsql.toml
57
57
  ```
58
58
 
59
59
  **Node (`npx dirsql`, TypeScript SDK).** Use the *npm package name* — but
@@ -1,7 +1,7 @@
1
1
  # Keep the index across restarts
2
2
 
3
3
  By default the database is ephemeral: rebuilt from your files on every
4
- startup and discarded on exit. The [`--persist [PATH]`](../reference/cli.md#server-mode)
4
+ startup and discarded on exit. The [`--persist [PATH]`](../reference/cli.md#dirsql-server)
5
5
  flag keeps the SQLite index on disk instead, so a restart only re-parses
6
6
  files that actually changed — the difference between seconds and
7
7
  milliseconds on large trees, and between re-running and skipping expensive
@@ -18,8 +18,8 @@ glob = "**/*"
18
18
 
19
19
  ## 1. Open the stream
20
20
 
21
- With the server running (`npx dirsql -c ./.dirsql.toml` /
22
- `uvx dirsql -c ./.dirsql.toml`), subscribe from another terminal:
21
+ With the server running (`npx dirsql server -c ./.dirsql.toml` /
22
+ `uvx dirsql server -c ./.dirsql.toml`), subscribe from another terminal:
23
23
 
24
24
  ```bash
25
25
  curl -N http://localhost:7117/events
@@ -10,7 +10,7 @@ embed each question at query time.
10
10
  ::: tip Just want it working?
11
11
  [`dirsql-plugin-embeddings`](https://pypi.org/project/dirsql-plugin-embeddings/)
12
12
  packages exactly what this guide builds, ready to install:
13
- `uvx --with dirsql-plugin-embeddings dirsql`. Keep reading to see how it's
13
+ `uvx --with dirsql-plugin-embeddings dirsql server`. Keep reading to see how it's
14
14
  built — the same three pieces, from scratch.
15
15
  :::
16
16