@jefuriiij/synthra 0.1.11 → 0.1.13

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.
package/CHANGELOG.md CHANGED
@@ -7,6 +7,31 @@ For older versions, see [GitHub Releases](https://github.com/jefuriiij/synthra/r
7
7
 
8
8
  ---
9
9
 
10
+ ## [0.1.13] — 2026-05-29
11
+
12
+ ### Fixed
13
+
14
+ - **Dashboard footer version is now dynamic.** Was hardcoded to `v0.1.8`
15
+ in the HTML and never updated. The dashboard server now injects the
16
+ running binary's version (from `package.json`) into the footer on every
17
+ `GET /` via a `__SYN_VERSION__` placeholder. Re-run `syn .` after an
18
+ update and the dashboard reflects the new version automatically.
19
+
20
+ ---
21
+
22
+ ## [0.1.12] — 2026-05-29
23
+
24
+ ### Fixed
25
+
26
+ - **`Language.query is deprecated` spam at scan time.** Every parsed file
27
+ printed the warning — 57 prints on a Flutter codebase, one per parsed
28
+ file. Switched all four parsers (TypeScript, JavaScript, Python, Dart,
29
+ plus the generic helper) from the deprecated `language.query(QUERY)`
30
+ to `new Query(language, QUERY)`. No behavior change, just clean
31
+ terminal output.
32
+
33
+ ---
34
+
10
35
  ## [0.1.11] — 2026-05-29
11
36
 
12
37
  ### Fixed
package/dist/cli/index.js CHANGED
@@ -18,7 +18,7 @@ var init_package = __esm({
18
18
  "package.json"() {
19
19
  package_default = {
20
20
  name: "@jefuriiij/synthra",
21
- version: "0.1.11",
21
+ version: "0.1.13",
22
22
  publishConfig: {
23
23
  access: "public"
24
24
  },
@@ -91,6 +91,7 @@ import sade from "sade";
91
91
  import { resolve as resolve4 } from "path";
92
92
 
93
93
  // src/dashboard/server.ts
94
+ init_package();
94
95
  import { serve } from "@hono/node-server";
95
96
  import { Hono } from "hono";
96
97
 
@@ -865,7 +866,7 @@ var public_default = `<!doctype html>\r
865
866
  \r
866
867
  <!-- ============ Footer ============ -->\r
867
868
  <footer class="foot">\r
868
- <div>Synth<em>ra</em> \xB7 v0.1.8</div>\r
869
+ <div>Synth<em>ra</em> \xB7 v__SYN_VERSION__</div>\r
869
870
  <div>Cost figures approximate \xB7 @jefuriiij</div>\r
870
871
  </footer>\r
871
872
  \r
@@ -1282,6 +1283,7 @@ var style_default = '/* Synthra dashboard \xB7 v0.2 \xB7 Cool Marine\r\n Darke
1282
1283
 
1283
1284
  // src/dashboard/server.ts
1284
1285
  var FALLBACK_RANGE = 9;
1286
+ var VERSION = package_default.version;
1285
1287
  async function startDashboard(paths, preferredPort = 8901) {
1286
1288
  const port = await findFreePort(preferredPort, preferredPort + FALLBACK_RANGE);
1287
1289
  if (port !== preferredPort) {
@@ -1290,7 +1292,7 @@ async function startDashboard(paths, preferredPort = 8901) {
1290
1292
  );
1291
1293
  }
1292
1294
  const app = new Hono();
1293
- app.get("/", (c) => c.html(public_default));
1295
+ app.get("/", (c) => c.html(public_default.replaceAll("__SYN_VERSION__", VERSION)));
1294
1296
  app.get("/style.css", (c) => {
1295
1297
  c.header("Content-Type", "text/css; charset=utf-8");
1296
1298
  c.header("Cache-Control", "no-cache");
@@ -2247,6 +2249,7 @@ import { createRequire } from "module";
2247
2249
  import { Language, Parser } from "web-tree-sitter";
2248
2250
 
2249
2251
  // src/scanner/parsers/_generic.ts
2252
+ import { Query } from "web-tree-sitter";
2250
2253
  function firstLine(text, max = 200) {
2251
2254
  const line = text.split(/\r?\n/, 1)[0] ?? "";
2252
2255
  return line.length > max ? line.slice(0, max) + "\u2026" : line;
@@ -2261,7 +2264,7 @@ async function runGenericParser(config, f, source) {
2261
2264
  const { parser, language } = await createParser(config.grammar);
2262
2265
  const tree = parser.parse(source);
2263
2266
  if (!tree) return { file: f, source, symbols, imports, calls: [] };
2264
- const query = language.query(config.query);
2267
+ const query = new Query(language, config.query);
2265
2268
  const matches = query.matches(tree.rootNode);
2266
2269
  for (const match of matches) {
2267
2270
  const byName = /* @__PURE__ */ new Map();
@@ -2392,6 +2395,7 @@ async function parseCSharp(f, source) {
2392
2395
  }
2393
2396
 
2394
2397
  // src/scanner/parsers/dart.ts
2398
+ import { Query as Query2 } from "web-tree-sitter";
2395
2399
  var QUERY4 = `
2396
2400
  (class_definition name: (identifier) @class.name) @class
2397
2401
  (mixin_declaration (identifier) @mixin.name) @mixin
@@ -2439,7 +2443,7 @@ async function parseDart(f, source) {
2439
2443
  const { parser, language } = await createParser("dart");
2440
2444
  const tree = parser.parse(source);
2441
2445
  if (!tree) return { file: f, source, symbols, imports, calls: [] };
2442
- const query = language.query(QUERY4);
2446
+ const query = new Query2(language, QUERY4);
2443
2447
  const matches = query.matches(tree.rootNode);
2444
2448
  for (const match of matches) {
2445
2449
  const byName = /* @__PURE__ */ new Map();
@@ -2583,6 +2587,7 @@ async function parsePhp(f, source) {
2583
2587
  }
2584
2588
 
2585
2589
  // src/scanner/parsers/python.ts
2590
+ import { Query as Query3 } from "web-tree-sitter";
2586
2591
  var QUERY9 = `
2587
2592
  (function_definition name: (identifier) @function.name) @function
2588
2593
  (class_definition name: (identifier) @class.name) @class
@@ -2601,7 +2606,7 @@ async function parsePython(f, source) {
2601
2606
  const { parser, language } = await createParser("python");
2602
2607
  const tree = parser.parse(source);
2603
2608
  if (!tree) return { file: f, source, symbols, imports, calls: [] };
2604
- const query = language.query(QUERY9);
2609
+ const query = new Query3(language, QUERY9);
2605
2610
  const matches = query.matches(tree.rootNode);
2606
2611
  for (const match of matches) {
2607
2612
  const byName = /* @__PURE__ */ new Map();
@@ -2699,6 +2704,7 @@ async function parseRust(f, source) {
2699
2704
  }
2700
2705
 
2701
2706
  // src/scanner/parsers/typescript.ts
2707
+ import { Query as Query4 } from "web-tree-sitter";
2702
2708
  var TS_QUERY = `
2703
2709
  (function_declaration name: (identifier) @function.name) @function
2704
2710
  (class_declaration name: (type_identifier) @class.name) @class
@@ -2748,7 +2754,7 @@ async function parseTypeScript(f, source) {
2748
2754
  const { parser, language } = await createParser(grammar);
2749
2755
  const tree = parser.parse(source);
2750
2756
  if (!tree) return { file: f, source, symbols, imports, calls: [] };
2751
- const query = language.query(queryFor(grammar));
2757
+ const query = new Query4(language, queryFor(grammar));
2752
2758
  const matches = query.matches(tree.rootNode);
2753
2759
  for (const match of matches) {
2754
2760
  const byName = /* @__PURE__ */ new Map();
@@ -5035,7 +5041,7 @@ async function spawnClaude(bin, opts) {
5035
5041
  }
5036
5042
 
5037
5043
  // src/cli/index.ts
5038
- var VERSION = package_default.version;
5044
+ var VERSION2 = package_default.version;
5039
5045
  function printReadyBanner(info) {
5040
5046
  log.info("");
5041
5047
  log.info(` \u2705 scanned ${info.scan.parsed} files \xB7 ${info.scan.symbolCount} symbols \xB7 ${info.scan.edgeCount} edges`);
@@ -5122,7 +5128,7 @@ async function defaultFlow(rawPath, opts) {
5122
5128
  }
5123
5129
  function buildProgram() {
5124
5130
  const prog = sade("syn");
5125
- prog.version(VERSION).describe("Local context engine for AI coding assistants.");
5131
+ prog.version(VERSION2).describe("Local context engine for AI coding assistants.");
5126
5132
  prog.command(". [path]", "Scan + MCP + dashboard + hooks. Default flow \u2014 use with the Claude Code IDE extension.", {
5127
5133
  default: true
5128
5134
  }).option("--resume <id>", "Resume an existing Claude session (only with --launch-cli)").option("--launch-cli", "Also spawn `claude` CLI in this terminal (legacy M3 behavior)", false).action(async (path, opts) => {