@specship/specship-win32-arm64 0.12.1 → 0.13.0

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 (64) hide show
  1. package/lib/dist/bin/specship.js +48 -12
  2. package/lib/dist/bin/specship.js.map +1 -1
  3. package/lib/dist/db/migrations.d.ts +1 -1
  4. package/lib/dist/db/migrations.d.ts.map +1 -1
  5. package/lib/dist/db/migrations.js +16 -1
  6. package/lib/dist/db/migrations.js.map +1 -1
  7. package/lib/dist/db/schema.sql +10 -0
  8. package/lib/dist/server/cli.js +9 -7
  9. package/lib/dist/server/product-version.js +44 -0
  10. package/lib/dist/server/routes/claude.js +153 -42
  11. package/lib/dist/server/routes/config.js +35 -0
  12. package/lib/dist/server/routes/graph.js +22 -1
  13. package/lib/dist/server/routes/mcp.js +510 -0
  14. package/lib/dist/server/routes/projects.js +31 -3
  15. package/lib/dist/server/routes/status.js +3 -0
  16. package/lib/dist/server/routes/workflow.js +29 -2
  17. package/lib/dist/server/server-config.js +38 -0
  18. package/lib/dist/server/server.js +128 -58
  19. package/lib/dist/ui/assets/geist-cyrillic-ext-wght-normal-DjL33-gN.woff2 +0 -0
  20. package/lib/dist/ui/assets/geist-cyrillic-wght-normal-BEAKL7Jp.woff2 +0 -0
  21. package/lib/dist/ui/assets/geist-latin-ext-wght-normal-DC-KSUi6.woff2 +0 -0
  22. package/lib/dist/ui/assets/geist-latin-wght-normal-BgDaEnEv.woff2 +0 -0
  23. package/lib/dist/ui/assets/geist-mono-cyrillic-ext-wght-normal-I4S5GZfc.woff2 +0 -0
  24. package/lib/dist/ui/assets/geist-mono-cyrillic-wght-normal-BmXc_FBt.woff2 +0 -0
  25. package/lib/dist/ui/assets/geist-mono-latin-ext-wght-normal-DrnZ1wKl.woff2 +0 -0
  26. package/lib/dist/ui/assets/geist-mono-latin-wght-normal-B_7UjwxQ.woff2 +0 -0
  27. package/lib/dist/ui/assets/geist-mono-symbols2-wght-normal-GZpp1pK2.woff2 +0 -0
  28. package/lib/dist/ui/assets/geist-mono-vietnamese-wght-normal-D8KDMBhC.woff2 +0 -0
  29. package/lib/dist/ui/assets/geist-vietnamese-wght-normal-6IgcOCM7.woff2 +0 -0
  30. package/lib/dist/ui/assets/index-D8e4LiVb.js +51 -0
  31. package/lib/dist/ui/assets/index-ezwX2EfG.css +1 -0
  32. package/lib/dist/ui/favicon-16.png +0 -0
  33. package/lib/dist/ui/favicon-180.png +0 -0
  34. package/lib/dist/ui/favicon-32.png +0 -0
  35. package/lib/dist/ui/favicon.svg +20 -0
  36. package/lib/dist/ui/index.html +17 -0
  37. package/lib/dist/update/resolve-latest.d.ts +14 -0
  38. package/lib/dist/update/resolve-latest.d.ts.map +1 -0
  39. package/lib/dist/update/resolve-latest.js +29 -0
  40. package/lib/dist/update/resolve-latest.js.map +1 -0
  41. package/lib/dist/update/run-installer.d.ts +13 -0
  42. package/lib/dist/update/run-installer.d.ts.map +1 -0
  43. package/lib/dist/update/run-installer.js +43 -0
  44. package/lib/dist/update/run-installer.js.map +1 -0
  45. package/lib/dist/update/updater.d.ts +53 -0
  46. package/lib/dist/update/updater.d.ts.map +1 -0
  47. package/lib/dist/update/updater.js +164 -0
  48. package/lib/dist/update/updater.js.map +1 -0
  49. package/lib/dist/workflows/executor.d.ts.map +1 -1
  50. package/lib/dist/workflows/executor.js +4 -0
  51. package/lib/dist/workflows/executor.js.map +1 -1
  52. package/lib/dist/workflows/runners/prompt.d.ts +6 -0
  53. package/lib/dist/workflows/runners/prompt.d.ts.map +1 -1
  54. package/lib/dist/workflows/runners/prompt.js +10 -0
  55. package/lib/dist/workflows/runners/prompt.js.map +1 -1
  56. package/lib/dist/workflows/runners/types.d.ts +12 -0
  57. package/lib/dist/workflows/runners/types.d.ts.map +1 -1
  58. package/lib/node_modules/.package-lock.json +1 -1
  59. package/lib/package.json +3 -2
  60. package/package.json +1 -1
  61. package/lib/dist/server/ssr/md.mjs +0 -83
  62. package/lib/dist/server/ssr/public/app.css +0 -1
  63. package/lib/dist/server/ssr/render.mjs +0 -596
  64. package/lib/dist/server/ssr/routes.js +0 -73
@@ -1,73 +0,0 @@
1
- import { readFileSync } from 'node:fs';
2
- import { fileURLToPath } from 'node:url';
3
- import { dirname, join } from 'node:path';
4
- export async function registerSsrRoutes(app) {
5
- const here = dirname(fileURLToPath(import.meta.url));
6
- // Server-local ESM module, copied next to this file by the build. No type
7
- // declarations — it renders HTML strings from API-shaped data.
8
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
9
- // @ts-expect-error -- untyped server-local module
10
- const R = await import('./render.mjs');
11
- const PUB = join(here, 'public');
12
- const inject = async (url) => {
13
- const res = await app.inject({ method: 'GET', url });
14
- try {
15
- return res.json();
16
- }
17
- catch {
18
- return {};
19
- }
20
- };
21
- const send = (reply, title, active, body) => reply.header('content-type', 'text/html; charset=utf-8').send(R['layout']({ title, activeHref: active, body }));
22
- // --- static assets (served by hand — no extra dependency) ---
23
- const assets = {
24
- '/app.css': ['app.css', 'text/css; charset=utf-8'],
25
- '/islands.js': ['islands.js', 'text/javascript; charset=utf-8'],
26
- '/islands/graph.js': [join('islands', 'graph.js'), 'text/javascript; charset=utf-8'],
27
- };
28
- for (const [route, spec] of Object.entries(assets)) {
29
- const [file, type] = spec;
30
- app.get(route, async (_req, reply) => reply.header('content-type', type).send(readFileSync(join(PUB, file))));
31
- }
32
- // --- pages ---
33
- const page = (route, title, fn) => {
34
- app.get(route, async (_req, reply) => {
35
- let body;
36
- try {
37
- body = await fn();
38
- }
39
- catch (e) {
40
- body = `<div class="page-head"><h1>${title}</h1></div><p class="muted">Couldn't load data: ${e instanceof Error ? e.message : String(e)}</p>`;
41
- }
42
- send(reply, title, route, body);
43
- });
44
- };
45
- app.get('/', async (_req, reply) => reply.redirect('/dashboard'));
46
- page('/dashboard', 'Dashboard', async () => R['renderDashboard'](await inject('/api/status'), await inject('/api/claude/stats')));
47
- app.get('/specs', async (_req, reply) => send(reply, 'Specs', '/specs', R['renderSpecs']((await inject('/api/specs'))['specs'] ?? [])));
48
- app.get('/specs/:id', async (req, reply) => {
49
- const id = req.params.id;
50
- send(reply, 'Spec', '/specs', R['renderSpecDetail'](await inject(`/api/spec/${encodeURIComponent(id)}`)));
51
- });
52
- page('/drift', 'Drift', async () => R['renderDrift'](await inject('/api/drift')));
53
- page('/maintainability', 'Maintainability', async () => R['renderMaintainability'](await inject('/api/maintainability')));
54
- page('/domain', 'Domain', async () => R['renderDomain'](await inject('/api/domain')));
55
- page('/memory', 'Memory', async () => R['renderMemory'](await inject('/api/memory')));
56
- page('/improvements', 'Improvements', async () => R['renderImprovements'](await inject('/api/reflect')));
57
- page('/compare', 'Compare', async () => R['renderCompare'](await inject('/api/claude/compare')));
58
- page('/costs', 'Costs', async () => R['renderCosts'](await inject('/api/claude/costs')));
59
- page('/specship-impact', 'SpecShip impact', async () => R['renderImpact'](await inject('/api/claude/specship-impact')));
60
- page('/runs', 'Runs', async () => R['renderRuns'](await inject('/api/workflows/runs')));
61
- app.get('/runs/:id', async (req, reply) => {
62
- const id = req.params.id;
63
- send(reply, 'Run', '/runs', R['renderRunDetail'](await inject(`/api/workflows/runs/${encodeURIComponent(id)}`)));
64
- });
65
- page('/sessions', 'Sessions', async () => R['renderSessions'](await inject('/api/claude/sessions')));
66
- app.get('/sessions/:id', async (req, reply) => {
67
- const id = req.params.id;
68
- send(reply, 'Session', '/sessions', R['renderSessionDetail'](await inject(`/api/claude/session/${encodeURIComponent(id)}`)));
69
- });
70
- page('/mcp', 'MCP', async () => R['renderMcp']((await inject('/api/mcp/servers'))['servers']));
71
- page('/graph', 'Graph', async () => R['renderGraph'](await inject('/api/graph/full?limit=250')));
72
- page('/heatmap', 'Heatmap', async () => R['renderHeatmap'](await inject('/api/claude/heatmap')));
73
- }