@thxgg/steward 0.1.15 → 0.1.17
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/.env.example +6 -0
- package/.output/nitro.json +1 -1
- package/.output/public/_nuxt/{qKRNa41x.js → 4r0X30JV.js} +1 -1
- package/.output/public/_nuxt/{uTyw4SRK.js → BMdjSp24.js} +1 -1
- package/.output/public/_nuxt/{BubpH_wW.js → BSZqAKg4.js} +1 -1
- package/.output/public/_nuxt/{nYTZJhvT.js → BdjPva1I.js} +1 -1
- package/.output/public/_nuxt/Beeir9iR.js +1 -0
- package/.output/public/_nuxt/Bh3vsUvl.js +1 -0
- package/.output/public/_nuxt/{CMu9GKTH.js → BlTKcjLJ.js} +2 -2
- package/.output/public/_nuxt/{BDqHART1.js → By7gAVcL.js} +1 -1
- package/.output/public/_nuxt/CbJfCtEa.js +1 -0
- package/.output/public/_nuxt/CbkpNvIu.js +141 -0
- package/.output/public/_nuxt/CmhLcqDu.js +1 -0
- package/.output/public/_nuxt/DC6iPLz1.js +30 -0
- package/.output/public/_nuxt/{C_NevjZD.js → DD--ojY9.js} +1 -1
- package/.output/public/_nuxt/Detail.DSyVQNdr.css +1 -0
- package/.output/public/_nuxt/DhKWRjCh.js +60 -0
- package/.output/public/_nuxt/_prd_.BkpxMFSV.css +1 -0
- package/.output/public/_nuxt/builds/latest.json +1 -1
- package/.output/public/_nuxt/builds/meta/f3f42dbd-d501-442b-871c-3d06157e7aa1.json +1 -0
- package/.output/public/_nuxt/c1sXju8w.js +1 -0
- package/.output/public/_nuxt/eGCjCghR.js +1 -0
- package/.output/public/_nuxt/nX8Sf7cz.js +13 -0
- package/.output/server/chunks/_/git-api.mjs +100 -7
- package/.output/server/chunks/_/git-api.mjs.map +1 -1
- package/.output/server/chunks/_/git.mjs +3 -10
- package/.output/server/chunks/_/git.mjs.map +1 -1
- package/.output/server/chunks/_/prd-service.mjs +234 -0
- package/.output/server/chunks/_/prd-service.mjs.map +1 -0
- package/.output/server/chunks/_/task-graph.mjs +3 -3
- package/.output/server/chunks/_/task-graph.mjs.map +1 -1
- package/.output/server/chunks/_/watcher.mjs +26 -46
- package/.output/server/chunks/_/watcher.mjs.map +1 -1
- package/.output/server/chunks/build/{Detail-DC-KJQ1f.mjs → Detail-MGwP_u2d.mjs} +63 -34
- package/.output/server/chunks/build/Detail-MGwP_u2d.mjs.map +1 -0
- package/.output/server/chunks/build/DiffViewer-styles-1.mjs-BFsE2PCW.mjs +4 -0
- package/.output/server/chunks/build/DiffViewer-styles-1.mjs-BFsE2PCW.mjs.map +1 -0
- package/.output/server/chunks/build/DiffViewer-styles.D2bqX3nK.mjs +8 -0
- package/.output/server/chunks/build/DiffViewer-styles.D2bqX3nK.mjs.map +1 -0
- package/.output/server/chunks/build/DiffViewer-styles.FoV36wuV.mjs +10 -0
- package/.output/server/chunks/build/DiffViewer-styles.FoV36wuV.mjs.map +1 -0
- package/.output/server/chunks/build/Viewer-styles.D6wYWFb1.mjs +8 -0
- package/.output/server/chunks/build/Viewer-styles.D6wYWFb1.mjs.map +1 -0
- package/.output/server/chunks/build/{_prd_-C1C4GAhW.mjs → _prd_-C-Aj4fVa.mjs} +75 -33
- package/.output/server/chunks/build/_prd_-C-Aj4fVa.mjs.map +1 -0
- package/.output/server/chunks/build/client.precomputed.mjs +1 -1
- package/.output/server/chunks/build/{default-DWCOHHTE.mjs → default-Cao5eO80.mjs} +4 -3
- package/.output/server/chunks/build/default-Cao5eO80.mjs.map +1 -0
- package/.output/server/chunks/build/error-404-Bf6kdO80.mjs +2 -1
- package/.output/server/chunks/build/error-500-D_bcARXN.mjs +2 -1
- package/.output/server/chunks/build/{index-CckL_NBD.mjs → index-ByZO4Bvq.mjs} +2 -2
- package/.output/server/chunks/build/index-ByZO4Bvq.mjs.map +1 -0
- package/.output/server/chunks/build/{index-QVeSHT3L.mjs → index-ljj9uTXI.mjs} +8 -5
- package/.output/server/chunks/build/index-ljj9uTXI.mjs.map +1 -0
- package/.output/server/chunks/build/nuxt-link-SvT1nf8Z.mjs +1 -1
- package/.output/server/chunks/build/{repo-graph-CTEkxiYd.mjs → repo-graph-EuhMeFt7.mjs} +25 -10
- package/.output/server/chunks/build/repo-graph-EuhMeFt7.mjs.map +1 -0
- package/.output/server/chunks/build/server.mjs +7 -6
- package/.output/server/chunks/build/styles.mjs +4 -4
- package/.output/server/chunks/build/{usePrd-SqcxGyFU.mjs → usePrd-f7ylhIqs.mjs} +10 -34
- package/.output/server/chunks/build/usePrd-f7ylhIqs.mjs.map +1 -0
- package/.output/server/chunks/nitro/nitro.mjs +1149 -720
- package/.output/server/chunks/nitro/nitro.mjs.map +1 -1
- package/.output/server/chunks/routes/api/browse.get.mjs +12 -6
- package/.output/server/chunks/routes/api/browse.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/index.get.mjs +2 -1
- package/.output/server/chunks/routes/api/index.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/index.post.mjs +3 -2
- package/.output/server/chunks/routes/api/index.post.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/git/commits.get.mjs +11 -13
- package/.output/server/chunks/routes/api/repos/_repoId/git/commits.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/git/diff.get.mjs +11 -6
- package/.output/server/chunks/routes/api/repos/_repoId/git/diff.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/git/file-content.get.mjs +31 -12
- package/.output/server/chunks/routes/api/repos/_repoId/git/file-content.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/git/file-diff.get.mjs +13 -13
- package/.output/server/chunks/routes/api/repos/_repoId/git/file-diff.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/graph.get.mjs +5 -1
- package/.output/server/chunks/routes/api/repos/_repoId/graph.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/graph.get.mjs +14 -1
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/graph.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/progress.get.mjs +20 -9
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/progress.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/tasks/_taskId/commits.get.mjs +20 -85
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/tasks/_taskId/commits.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/tasks.get.mjs +20 -9
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/tasks.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug_.get.mjs +30 -50
- package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug_.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/prds.get.mjs +19 -49
- package/.output/server/chunks/routes/api/repos/_repoId/prds.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId/refresh-git-repos.post.mjs +6 -13
- package/.output/server/chunks/routes/api/repos/_repoId/refresh-git-repos.post.mjs.map +1 -1
- package/.output/server/chunks/routes/api/repos/_repoId_.delete.mjs +2 -1
- package/.output/server/chunks/routes/api/repos/_repoId_.delete.mjs.map +1 -1
- package/.output/server/chunks/routes/api/runtime.get.mjs +3 -2
- package/.output/server/chunks/routes/api/runtime.get.mjs.map +1 -1
- package/.output/server/chunks/routes/api/watch.get.mjs +5 -4
- package/.output/server/chunks/routes/api/watch.get.mjs.map +1 -1
- package/.output/server/chunks/routes/renderer.mjs +1 -1
- package/.output/server/index.mjs +3 -2
- package/.output/server/index.mjs.map +1 -1
- package/.output/server/node_modules/zod/index.js +4 -0
- package/.output/server/node_modules/zod/package.json +118 -0
- package/.output/server/node_modules/zod/v3/ZodError.js +133 -0
- package/.output/server/node_modules/zod/v3/errors.js +9 -0
- package/.output/server/node_modules/zod/v3/external.js +6 -0
- package/.output/server/node_modules/zod/v3/helpers/errorUtil.js +6 -0
- package/.output/server/node_modules/zod/v3/helpers/parseUtil.js +109 -0
- package/.output/server/node_modules/zod/v3/helpers/typeAliases.js +1 -0
- package/.output/server/node_modules/zod/v3/helpers/util.js +133 -0
- package/.output/server/node_modules/zod/v3/locales/en.js +109 -0
- package/.output/server/node_modules/zod/v3/types.js +3693 -0
- package/.output/server/package.json +2 -1
- package/README.md +7 -2
- package/dist/host/src/api/prds.js +6 -172
- package/dist/host/src/api/repos.js +3 -16
- package/dist/host/src/api/state.js +7 -2
- package/dist/host/src/executor-runner.js +368 -0
- package/dist/host/src/executor.js +138 -260
- package/dist/host/src/index.js +7 -2
- package/dist/host/src/mcp.js +27 -1
- package/dist/host/src/ui.js +18 -3
- package/dist/server/utils/change-events.js +33 -0
- package/dist/server/utils/git.js +11 -16
- package/dist/server/utils/prd-service.js +235 -0
- package/dist/server/utils/prd-state.js +57 -45
- package/dist/server/utils/repos.js +58 -13
- package/dist/server/utils/state-schema.js +61 -0
- package/dist/server/utils/task-graph.js +2 -2
- package/package.json +2 -1
- package/.output/public/_nuxt/-k8zG74W.js +0 -61
- package/.output/public/_nuxt/B-5VWizU.js +0 -1
- package/.output/public/_nuxt/BMAq0QVD.js +0 -42
- package/.output/public/_nuxt/BPeTf9dd.js +0 -1
- package/.output/public/_nuxt/C2HGkiSP.js +0 -1
- package/.output/public/_nuxt/CVvrkZkq.js +0 -1
- package/.output/public/_nuxt/Detail.CzXXlavD.css +0 -1
- package/.output/public/_nuxt/_prd_.KTotLoF_.css +0 -1
- package/.output/public/_nuxt/builds/meta/c1a7997d-8d53-4718-ad03-a977e05e2523.json +0 -1
- package/.output/public/_nuxt/qt5OEWHC.js +0 -1
- package/.output/public/_nuxt/wbj-mIhK.js +0 -1
- package/.output/server/chunks/build/Detail-DC-KJQ1f.mjs.map +0 -1
- package/.output/server/chunks/build/DiffViewer-styles-1.mjs-D0sb4vsK.mjs +0 -4
- package/.output/server/chunks/build/DiffViewer-styles-1.mjs-D0sb4vsK.mjs.map +0 -1
- package/.output/server/chunks/build/DiffViewer-styles.CkSjCQ0r.mjs +0 -10
- package/.output/server/chunks/build/DiffViewer-styles.CkSjCQ0r.mjs.map +0 -1
- package/.output/server/chunks/build/DiffViewer-styles.FJJuYjYB.mjs +0 -8
- package/.output/server/chunks/build/DiffViewer-styles.FJJuYjYB.mjs.map +0 -1
- package/.output/server/chunks/build/Viewer-styles.CshnetGw.mjs +0 -8
- package/.output/server/chunks/build/Viewer-styles.CshnetGw.mjs.map +0 -1
- package/.output/server/chunks/build/_prd_-C1C4GAhW.mjs.map +0 -1
- package/.output/server/chunks/build/default-DWCOHHTE.mjs.map +0 -1
- package/.output/server/chunks/build/index-CckL_NBD.mjs.map +0 -1
- package/.output/server/chunks/build/index-QVeSHT3L.mjs.map +0 -1
- package/.output/server/chunks/build/repo-graph-CTEkxiYd.mjs.map +0 -1
- package/.output/server/chunks/build/usePrd-SqcxGyFU.mjs.map +0 -1
- package/.output/server/node_modules/shiki/dist/bundle-web.mjs +0 -366
package/.output/server/chunks/routes/api/repos/_repoId/prd/_prdSlug/tasks/_taskId/commits.get.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { d as defineEventHandler, a as getRouterParam, c as createError,
|
|
2
|
-
import {
|
|
1
|
+
import { d as defineEventHandler, a as getRouterParam, c as createError, f as getRepoById } from '../../../../../../../../nitro/nitro.mjs';
|
|
2
|
+
import { e as resolveTaskCommits } from '../../../../../../../../_/prd-service.mjs';
|
|
3
3
|
import 'node:http';
|
|
4
4
|
import 'node:https';
|
|
5
5
|
import 'node:events';
|
|
@@ -7,12 +7,16 @@ import 'node:buffer';
|
|
|
7
7
|
import 'node:fs';
|
|
8
8
|
import 'node:path';
|
|
9
9
|
import 'node:crypto';
|
|
10
|
-
import 'node:os';
|
|
11
10
|
import 'node:url';
|
|
11
|
+
import 'node:os';
|
|
12
|
+
import 'zod';
|
|
13
|
+
import '../../../../../../../../_/git.mjs';
|
|
12
14
|
import 'node:child_process';
|
|
13
15
|
|
|
16
|
+
function normalizeErrorMessage(message) {
|
|
17
|
+
return message.replace(/\s+/g, " ").trim();
|
|
18
|
+
}
|
|
14
19
|
const commits_get = defineEventHandler(async (event) => {
|
|
15
|
-
var _a;
|
|
16
20
|
const repoId = getRouterParam(event, "repoId");
|
|
17
21
|
const prdSlug = getRouterParam(event, "prdSlug");
|
|
18
22
|
const taskId = getRouterParam(event, "taskId");
|
|
@@ -22,99 +26,30 @@ const commits_get = defineEventHandler(async (event) => {
|
|
|
22
26
|
statusMessage: "Repository ID, PRD slug, and task ID are required"
|
|
23
27
|
});
|
|
24
28
|
}
|
|
25
|
-
const
|
|
26
|
-
const repo = repos.find((r) => r.id === repoId);
|
|
29
|
+
const repo = await getRepoById(repoId);
|
|
27
30
|
if (!repo) {
|
|
28
31
|
throw createError({
|
|
29
32
|
statusCode: 404,
|
|
30
33
|
statusMessage: "Repository not found"
|
|
31
34
|
});
|
|
32
35
|
}
|
|
33
|
-
await migrateLegacyStateForRepo(repo);
|
|
34
|
-
let progress = null;
|
|
35
36
|
try {
|
|
36
|
-
|
|
37
|
-
progress = (_a = state == null ? void 0 : state.progress) != null ? _a : null;
|
|
37
|
+
return await resolveTaskCommits(repo, prdSlug, taskId);
|
|
38
38
|
} catch (error) {
|
|
39
|
+
const message = normalizeErrorMessage(error.message);
|
|
40
|
+
if (message.includes("Invalid PRD slug")) {
|
|
41
|
+
throw createError({
|
|
42
|
+
statusCode: 400,
|
|
43
|
+
statusMessage: "Invalid PRD slug",
|
|
44
|
+
message
|
|
45
|
+
});
|
|
46
|
+
}
|
|
39
47
|
throw createError({
|
|
40
48
|
statusCode: 500,
|
|
41
|
-
statusMessage: "Failed to
|
|
42
|
-
message
|
|
49
|
+
statusMessage: "Failed to resolve task commits",
|
|
50
|
+
message
|
|
43
51
|
});
|
|
44
52
|
}
|
|
45
|
-
if (!progress) {
|
|
46
|
-
return [];
|
|
47
|
-
}
|
|
48
|
-
const taskLogs = Array.isArray(progress.taskLogs) ? progress.taskLogs : [];
|
|
49
|
-
const taskLog = taskLogs.find((log) => log.taskId === taskId);
|
|
50
|
-
if (!taskLog) {
|
|
51
|
-
return [];
|
|
52
|
-
}
|
|
53
|
-
if (!taskLog.commits || taskLog.commits.length === 0) {
|
|
54
|
-
return [];
|
|
55
|
-
}
|
|
56
|
-
const resolvedCommits = [];
|
|
57
|
-
const failedEntries = [];
|
|
58
|
-
for (const commitEntry of taskLog.commits) {
|
|
59
|
-
try {
|
|
60
|
-
const resolved = await resolveCommitRepo(repo, commitEntry);
|
|
61
|
-
resolvedCommits.push({
|
|
62
|
-
sha: resolved.sha,
|
|
63
|
-
repo: resolved.repoPath
|
|
64
|
-
});
|
|
65
|
-
} catch {
|
|
66
|
-
failedEntries.push(commitEntry);
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
if (failedEntries.length > 0) {
|
|
70
|
-
const newGitRepos = await discoverGitRepos(repo.path);
|
|
71
|
-
const existingPaths = new Set((repo.gitRepos || []).map((gr) => gr.relativePath));
|
|
72
|
-
const hasNewRepos = newGitRepos.some((gr) => !existingPaths.has(gr.relativePath));
|
|
73
|
-
if (hasNewRepos) {
|
|
74
|
-
const repos2 = await getRepos();
|
|
75
|
-
const repoIndex = repos2.findIndex((r) => r.id === repoId);
|
|
76
|
-
if (repoIndex !== -1) {
|
|
77
|
-
const updatedRepo = {
|
|
78
|
-
...repos2[repoIndex],
|
|
79
|
-
gitRepos: newGitRepos.length > 0 ? newGitRepos : void 0
|
|
80
|
-
};
|
|
81
|
-
repos2[repoIndex] = updatedRepo;
|
|
82
|
-
await saveRepos(repos2);
|
|
83
|
-
for (const commitEntry of failedEntries) {
|
|
84
|
-
try {
|
|
85
|
-
const resolved = await resolveCommitRepo(updatedRepo, commitEntry);
|
|
86
|
-
resolvedCommits.push({
|
|
87
|
-
sha: resolved.sha,
|
|
88
|
-
repo: resolved.repoPath
|
|
89
|
-
});
|
|
90
|
-
} catch {
|
|
91
|
-
const sha = typeof commitEntry === "string" ? commitEntry : commitEntry.sha;
|
|
92
|
-
resolvedCommits.push({
|
|
93
|
-
sha,
|
|
94
|
-
repo: ""
|
|
95
|
-
});
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
} else {
|
|
99
|
-
for (const commitEntry of failedEntries) {
|
|
100
|
-
const sha = typeof commitEntry === "string" ? commitEntry : commitEntry.sha;
|
|
101
|
-
resolvedCommits.push({
|
|
102
|
-
sha,
|
|
103
|
-
repo: ""
|
|
104
|
-
});
|
|
105
|
-
}
|
|
106
|
-
}
|
|
107
|
-
} else {
|
|
108
|
-
for (const commitEntry of failedEntries) {
|
|
109
|
-
const sha = typeof commitEntry === "string" ? commitEntry : commitEntry.sha;
|
|
110
|
-
resolvedCommits.push({
|
|
111
|
-
sha,
|
|
112
|
-
repo: ""
|
|
113
|
-
});
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
return resolvedCommits;
|
|
118
53
|
});
|
|
119
54
|
|
|
120
55
|
export { commits_get as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"commits.get.mjs","sources":["../../../../../../../../../../../server/api/repos/[repoId]/prd/[prdSlug]/tasks/[taskId]/commits.get.ts"],"names":[
|
|
1
|
+
{"version":3,"file":"commits.get.mjs","sources":["../../../../../../../../../../../server/api/repos/[repoId]/prd/[prdSlug]/tasks/[taskId]/commits.get.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAGA,SAAA,sBAAA,OAAA,EAAA;AACA,EAAA,OAAA,OAAA,CAAA,OAAA,CAAA,MAAA,EAAA,GAAA,EAAA,IAAA,EAAA;AACA;AAEA,oBAAA,kBAAA,CAAA,OAAA,KAAA,KAAA;AACA,EAAA,MAAA,MAAA,GAAA,cAAA,CAAA,KAAA,EAAA,QAAA,CAAA;AACA,EAAA,MAAA,OAAA,GAAA,cAAA,CAAA,KAAA,EAAA,SAAA,CAAA;AACA,EAAA,MAAA,MAAA,GAAA,cAAA,CAAA,KAAA,EAAA,QAAA,CAAA;AAEA,EAAA,IAAA,CAAA,MAAA,IAAA,CAAA,OAAA,IAAA,CAAA,MAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,MAAA,IAAA,GAAA,MAAA,WAAA,CAAA,MAAA,CAAA;AACA,EAAA,IAAA,CAAA,IAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,IAAA;AACA,IAAA,OAAA,MAAA,kBAAA,CAAA,IAAA,EAAA,OAAA,EAAA,MAAA,CAAA;AAAA,EACA,SAAA,KAAA,EAAA;AACA,IAAA,MAAA,OAAA,GAAA,qBAAA,CAAA,KAAA,CAAA,OAAA,CAAA;AAEA,IAAA,IAAA,OAAA,CAAA,QAAA,CAAA,kBAAA,CAAA,EAAA;AACA,MAAA,MAAA,WAAA,CAAA;AAAA,QACA,UAAA,EAAA,GAAA;AAAA,QACA,aAAA,EAAA,kBAAA;AAAA,QACA;AAAA,OACA,CAAA;AAAA,IACA;AAEA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA,gCAAA;AAAA,MACA;AAAA,KACA,CAAA;AAAA,EACA;AACA,CAAA,CAAA;;;;"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { d as defineEventHandler, a as getRouterParam, c as createError,
|
|
1
|
+
import { d as defineEventHandler, a as getRouterParam, c as createError, f as getRepoById } from '../../../../../../nitro/nitro.mjs';
|
|
2
|
+
import { d as readPrdTasks } from '../../../../../../_/prd-service.mjs';
|
|
2
3
|
import 'node:http';
|
|
3
4
|
import 'node:https';
|
|
4
5
|
import 'node:events';
|
|
@@ -6,11 +7,16 @@ import 'node:buffer';
|
|
|
6
7
|
import 'node:fs';
|
|
7
8
|
import 'node:path';
|
|
8
9
|
import 'node:crypto';
|
|
9
|
-
import 'node:os';
|
|
10
10
|
import 'node:url';
|
|
11
|
+
import 'node:os';
|
|
12
|
+
import 'zod';
|
|
13
|
+
import '../../../../../../_/git.mjs';
|
|
14
|
+
import 'node:child_process';
|
|
11
15
|
|
|
16
|
+
function normalizeErrorMessage(message) {
|
|
17
|
+
return message.replace(/\s+/g, " ").trim();
|
|
18
|
+
}
|
|
12
19
|
const tasks_get = defineEventHandler(async (event) => {
|
|
13
|
-
var _a;
|
|
14
20
|
const repoId = getRouterParam(event, "repoId");
|
|
15
21
|
const prdSlug = getRouterParam(event, "prdSlug");
|
|
16
22
|
if (!repoId || !prdSlug) {
|
|
@@ -19,23 +25,28 @@ const tasks_get = defineEventHandler(async (event) => {
|
|
|
19
25
|
statusMessage: "Repository ID and PRD slug are required"
|
|
20
26
|
});
|
|
21
27
|
}
|
|
22
|
-
const
|
|
23
|
-
const repo = repos.find((r) => r.id === repoId);
|
|
28
|
+
const repo = await getRepoById(repoId);
|
|
24
29
|
if (!repo) {
|
|
25
30
|
throw createError({
|
|
26
31
|
statusCode: 404,
|
|
27
32
|
statusMessage: "Repository not found"
|
|
28
33
|
});
|
|
29
34
|
}
|
|
30
|
-
await migrateLegacyStateForRepo(repo);
|
|
31
35
|
try {
|
|
32
|
-
|
|
33
|
-
return (_a = state == null ? void 0 : state.tasks) != null ? _a : null;
|
|
36
|
+
return await readPrdTasks(repo, prdSlug);
|
|
34
37
|
} catch (error) {
|
|
38
|
+
const message = normalizeErrorMessage(error.message);
|
|
39
|
+
if (message.includes("Invalid PRD slug")) {
|
|
40
|
+
throw createError({
|
|
41
|
+
statusCode: 400,
|
|
42
|
+
statusMessage: "Invalid PRD slug",
|
|
43
|
+
message
|
|
44
|
+
});
|
|
45
|
+
}
|
|
35
46
|
throw createError({
|
|
36
47
|
statusCode: 500,
|
|
37
48
|
statusMessage: "Failed to read task state",
|
|
38
|
-
message
|
|
49
|
+
message
|
|
39
50
|
});
|
|
40
51
|
}
|
|
41
52
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tasks.get.mjs","sources":["../../../../../../../../../server/api/repos/[repoId]/prd/[prdSlug]/tasks.get.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"tasks.get.mjs","sources":["../../../../../../../../../server/api/repos/[repoId]/prd/[prdSlug]/tasks.get.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAGA,SAAA,sBAAA,OAAA,EAAA;AACA,EAAA,OAAA,OAAA,CAAA,OAAA,CAAA,MAAA,EAAA,GAAA,EAAA,IAAA,EAAA;AACA;AAEA,kBAAA,kBAAA,CAAA,OAAA,KAAA,KAAA;AACA,EAAA,MAAA,MAAA,GAAA,cAAA,CAAA,KAAA,EAAA,QAAA,CAAA;AACA,EAAA,MAAA,OAAA,GAAA,cAAA,CAAA,KAAA,EAAA,SAAA,CAAA;AAEA,EAAA,IAAA,CAAA,MAAA,IAAA,CAAA,OAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,MAAA,IAAA,GAAA,MAAA,WAAA,CAAA,MAAA,CAAA;AACA,EAAA,IAAA,CAAA,IAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,IAAA;AACA,IAAA,OAAA,MAAA,YAAA,CAAA,IAAA,EAAA,OAAA,CAAA;AAAA,EACA,SAAA,KAAA,EAAA;AACA,IAAA,MAAA,OAAA,GAAA,qBAAA,CAAA,KAAA,CAAA,OAAA,CAAA;AAEA,IAAA,IAAA,OAAA,CAAA,QAAA,CAAA,kBAAA,CAAA,EAAA;AACA,MAAA,MAAA,WAAA,CAAA;AAAA,QACA,UAAA,EAAA,GAAA;AAAA,QACA,aAAA,EAAA,kBAAA;AAAA,QACA;AAAA,OACA,CAAA;AAAA,IACA;AAEA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA,2BAAA;AAAA,MACA;AAAA,KACA,CAAA;AAAA,EACA;AACA,CAAA,CAAA;;;;"}
|
|
@@ -1,39 +1,20 @@
|
|
|
1
|
-
import { d as defineEventHandler, a as getRouterParam, c as createError,
|
|
2
|
-
import {
|
|
3
|
-
import { join } from 'node:path';
|
|
1
|
+
import { d as defineEventHandler, a as getRouterParam, c as createError, f as getRepoById } from '../../../../../nitro/nitro.mjs';
|
|
2
|
+
import { r as readPrdDocument } from '../../../../../_/prd-service.mjs';
|
|
4
3
|
import 'node:http';
|
|
5
4
|
import 'node:https';
|
|
6
5
|
import 'node:events';
|
|
7
6
|
import 'node:buffer';
|
|
7
|
+
import 'node:fs';
|
|
8
|
+
import 'node:path';
|
|
8
9
|
import 'node:crypto';
|
|
9
|
-
import 'node:os';
|
|
10
10
|
import 'node:url';
|
|
11
|
+
import 'node:os';
|
|
12
|
+
import 'zod';
|
|
13
|
+
import '../../../../../_/git.mjs';
|
|
14
|
+
import 'node:child_process';
|
|
11
15
|
|
|
12
|
-
function
|
|
13
|
-
|
|
14
|
-
const authorMatch = content.match(/\*{0,2}Author\*{0,2}:\*{0,2}\s*(.+?)(?:\n|$)/i);
|
|
15
|
-
if (authorMatch && authorMatch[1]) {
|
|
16
|
-
metadata.author = authorMatch[1].trim();
|
|
17
|
-
}
|
|
18
|
-
const dateMatch = content.match(/\*{0,2}Date\*{0,2}:\*{0,2}\s*(.+?)(?:\n|$)/i);
|
|
19
|
-
if (dateMatch && dateMatch[1]) {
|
|
20
|
-
metadata.date = dateMatch[1].trim();
|
|
21
|
-
}
|
|
22
|
-
const statusMatch = content.match(/\*{0,2}Status\*{0,2}:\*{0,2}\s*(.+?)(?:\n|$)/i);
|
|
23
|
-
if (statusMatch && statusMatch[1]) {
|
|
24
|
-
metadata.status = statusMatch[1].trim();
|
|
25
|
-
}
|
|
26
|
-
const shortcutLinkMatch = content.match(/\[([Ss][Cc]-\d+)\]\(([^)]+)\)/);
|
|
27
|
-
if (shortcutLinkMatch && shortcutLinkMatch[1] && shortcutLinkMatch[2]) {
|
|
28
|
-
metadata.shortcutStory = shortcutLinkMatch[1];
|
|
29
|
-
metadata.shortcutUrl = shortcutLinkMatch[2];
|
|
30
|
-
} else {
|
|
31
|
-
const shortcutIdMatch = content.match(/\*{0,2}Shortcut(?:\s+Story)?\*{0,2}:\*{0,2}\s*([Ss][Cc]-\d+)/i);
|
|
32
|
-
if (shortcutIdMatch && shortcutIdMatch[1]) {
|
|
33
|
-
metadata.shortcutStory = shortcutIdMatch[1];
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
return metadata;
|
|
16
|
+
function normalizeErrorMessage(message) {
|
|
17
|
+
return message.replace(/\s+/g, " ").trim();
|
|
37
18
|
}
|
|
38
19
|
const _prdSlug__get = defineEventHandler(async (event) => {
|
|
39
20
|
const repoId = getRouterParam(event, "repoId");
|
|
@@ -44,37 +25,36 @@ const _prdSlug__get = defineEventHandler(async (event) => {
|
|
|
44
25
|
statusMessage: "Repository ID and PRD slug are required"
|
|
45
26
|
});
|
|
46
27
|
}
|
|
47
|
-
const
|
|
48
|
-
const repo = repos.find((r) => r.id === repoId);
|
|
28
|
+
const repo = await getRepoById(repoId);
|
|
49
29
|
if (!repo) {
|
|
50
30
|
throw createError({
|
|
51
31
|
statusCode: 404,
|
|
52
32
|
statusMessage: "Repository not found"
|
|
53
33
|
});
|
|
54
34
|
}
|
|
55
|
-
const prdPath = join(repo.path, "docs", "prd", `${prdSlug}.md`);
|
|
56
|
-
let content;
|
|
57
35
|
try {
|
|
58
|
-
|
|
59
|
-
} catch {
|
|
36
|
+
return await readPrdDocument(repo, prdSlug);
|
|
37
|
+
} catch (error) {
|
|
38
|
+
const message = normalizeErrorMessage(error.message);
|
|
39
|
+
if (message.includes("Invalid PRD slug")) {
|
|
40
|
+
throw createError({
|
|
41
|
+
statusCode: 400,
|
|
42
|
+
statusMessage: "Invalid PRD slug",
|
|
43
|
+
message
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
if (message.includes("PRD not found")) {
|
|
47
|
+
throw createError({
|
|
48
|
+
statusCode: 404,
|
|
49
|
+
statusMessage: "PRD not found"
|
|
50
|
+
});
|
|
51
|
+
}
|
|
60
52
|
throw createError({
|
|
61
|
-
statusCode:
|
|
62
|
-
statusMessage: "PRD
|
|
53
|
+
statusCode: 500,
|
|
54
|
+
statusMessage: "Failed to load PRD document",
|
|
55
|
+
message
|
|
63
56
|
});
|
|
64
57
|
}
|
|
65
|
-
let name = prdSlug;
|
|
66
|
-
const h1Match = content.match(/^#\s+(.+)$/m);
|
|
67
|
-
if (h1Match && h1Match[1]) {
|
|
68
|
-
name = h1Match[1].trim();
|
|
69
|
-
}
|
|
70
|
-
const metadata = parseMetadata(content);
|
|
71
|
-
const document = {
|
|
72
|
-
slug: prdSlug,
|
|
73
|
-
name,
|
|
74
|
-
content,
|
|
75
|
-
metadata
|
|
76
|
-
};
|
|
77
|
-
return document;
|
|
78
58
|
});
|
|
79
59
|
|
|
80
60
|
export { _prdSlug__get as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"_prdSlug_.get.mjs","sources":["../../../../../../../../server/api/repos/[repoId]/prd/[prdSlug].get.ts"],"names":[
|
|
1
|
+
{"version":3,"file":"_prdSlug_.get.mjs","sources":["../../../../../../../../server/api/repos/[repoId]/prd/[prdSlug].get.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAGA,SAAA,sBAAA,OAAA,EAAA;AACA,EAAA,OAAA,OAAA,CAAA,OAAA,CAAA,MAAA,EAAA,GAAA,EAAA,IAAA,EAAA;AACA;AAEA,sBAAA,kBAAA,CAAA,OAAA,KAAA,KAAA;AACA,EAAA,MAAA,MAAA,GAAA,cAAA,CAAA,KAAA,EAAA,QAAA,CAAA;AACA,EAAA,MAAA,OAAA,GAAA,cAAA,CAAA,KAAA,EAAA,SAAA,CAAA;AAEA,EAAA,IAAA,CAAA,MAAA,IAAA,CAAA,OAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,MAAA,IAAA,GAAA,MAAA,WAAA,CAAA,MAAA,CAAA;AACA,EAAA,IAAA,CAAA,IAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,IAAA;AACA,IAAA,OAAA,MAAA,eAAA,CAAA,IAAA,EAAA,OAAA,CAAA;AAAA,EACA,SAAA,KAAA,EAAA;AACA,IAAA,MAAA,OAAA,GAAA,qBAAA,CAAA,KAAA,CAAA,OAAA,CAAA;AAEA,IAAA,IAAA,OAAA,CAAA,QAAA,CAAA,kBAAA,CAAA,EAAA;AACA,MAAA,MAAA,WAAA,CAAA;AAAA,QACA,UAAA,EAAA,GAAA;AAAA,QACA,aAAA,EAAA,kBAAA;AAAA,QACA;AAAA,OACA,CAAA;AAAA,IACA;AAEA,IAAA,IAAA,OAAA,CAAA,QAAA,CAAA,eAAA,CAAA,EAAA;AACA,MAAA,MAAA,WAAA,CAAA;AAAA,QACA,UAAA,EAAA,GAAA;AAAA,QACA,aAAA,EAAA;AAAA,OACA,CAAA;AAAA,IACA;AAEA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA,6BAAA;AAAA,MACA;AAAA,KACA,CAAA;AAAA,EACA;AACA,CAAA,CAAA;;;;"}
|
|
@@ -1,14 +1,21 @@
|
|
|
1
|
-
import { d as defineEventHandler, a as getRouterParam, c as createError,
|
|
2
|
-
import {
|
|
3
|
-
import { join, basename } from 'node:path';
|
|
1
|
+
import { d as defineEventHandler, a as getRouterParam, c as createError, f as getRepoById } from '../../../../nitro/nitro.mjs';
|
|
2
|
+
import { l as listPrdDocuments } from '../../../../_/prd-service.mjs';
|
|
4
3
|
import 'node:http';
|
|
5
4
|
import 'node:https';
|
|
6
5
|
import 'node:events';
|
|
7
6
|
import 'node:buffer';
|
|
7
|
+
import 'node:fs';
|
|
8
|
+
import 'node:path';
|
|
8
9
|
import 'node:crypto';
|
|
9
|
-
import 'node:os';
|
|
10
10
|
import 'node:url';
|
|
11
|
+
import 'node:os';
|
|
12
|
+
import 'zod';
|
|
13
|
+
import '../../../../_/git.mjs';
|
|
14
|
+
import 'node:child_process';
|
|
11
15
|
|
|
16
|
+
function normalizeErrorMessage(message) {
|
|
17
|
+
return message.replace(/\s+/g, " ").trim();
|
|
18
|
+
}
|
|
12
19
|
const prds_get = defineEventHandler(async (event) => {
|
|
13
20
|
const repoId = getRouterParam(event, "repoId");
|
|
14
21
|
if (!repoId) {
|
|
@@ -17,59 +24,22 @@ const prds_get = defineEventHandler(async (event) => {
|
|
|
17
24
|
statusMessage: "Repository ID is required"
|
|
18
25
|
});
|
|
19
26
|
}
|
|
20
|
-
const
|
|
21
|
-
const repo = repos.find((r) => r.id === repoId);
|
|
27
|
+
const repo = await getRepoById(repoId);
|
|
22
28
|
if (!repo) {
|
|
23
29
|
throw createError({
|
|
24
30
|
statusCode: 404,
|
|
25
31
|
statusMessage: "Repository not found"
|
|
26
32
|
});
|
|
27
33
|
}
|
|
28
|
-
await migrateLegacyStateForRepo(repo);
|
|
29
|
-
const prdDir = join(repo.path, "docs", "prd");
|
|
30
|
-
let prdFiles = [];
|
|
31
34
|
try {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
35
|
+
return await listPrdDocuments(repo);
|
|
36
|
+
} catch (error) {
|
|
37
|
+
throw createError({
|
|
38
|
+
statusCode: 500,
|
|
39
|
+
statusMessage: "Failed to load PRD list",
|
|
40
|
+
message: normalizeErrorMessage(error.message)
|
|
41
|
+
});
|
|
36
42
|
}
|
|
37
|
-
const stateSummaries = await getPrdStateSummaries(repo.id);
|
|
38
|
-
const prds = await Promise.all(
|
|
39
|
-
prdFiles.map(async (filename) => {
|
|
40
|
-
const slug = basename(filename, ".md");
|
|
41
|
-
const filePath = join(prdDir, filename);
|
|
42
|
-
let name = slug;
|
|
43
|
-
let modifiedAt = 0;
|
|
44
|
-
try {
|
|
45
|
-
const [content, stat] = await Promise.all([
|
|
46
|
-
promises.readFile(filePath, "utf-8"),
|
|
47
|
-
promises.stat(filePath)
|
|
48
|
-
]);
|
|
49
|
-
modifiedAt = stat.mtime.getTime();
|
|
50
|
-
const h1Match = content.match(/^#\s+(.+)$/m);
|
|
51
|
-
if (h1Match && h1Match[1]) {
|
|
52
|
-
name = h1Match[1].trim();
|
|
53
|
-
}
|
|
54
|
-
} catch {
|
|
55
|
-
}
|
|
56
|
-
const stateSummary = stateSummaries.get(slug);
|
|
57
|
-
const hasState = !!(stateSummary == null ? void 0 : stateSummary.hasState);
|
|
58
|
-
const taskCount = stateSummary == null ? void 0 : stateSummary.taskCount;
|
|
59
|
-
const completedCount = stateSummary == null ? void 0 : stateSummary.completedCount;
|
|
60
|
-
return {
|
|
61
|
-
slug,
|
|
62
|
-
name,
|
|
63
|
-
source: `docs/prd/${filename}`,
|
|
64
|
-
hasState,
|
|
65
|
-
modifiedAt,
|
|
66
|
-
...taskCount !== void 0 && { taskCount },
|
|
67
|
-
...completedCount !== void 0 && { completedCount }
|
|
68
|
-
};
|
|
69
|
-
})
|
|
70
|
-
);
|
|
71
|
-
prds.sort((a, b) => b.modifiedAt - a.modifiedAt);
|
|
72
|
-
return prds;
|
|
73
43
|
});
|
|
74
44
|
|
|
75
45
|
export { prds_get as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prds.get.mjs","sources":["../../../../../../../server/api/repos/[repoId]/prds.get.ts"],"names":[
|
|
1
|
+
{"version":3,"file":"prds.get.mjs","sources":["../../../../../../../server/api/repos/[repoId]/prds.get.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAGA,SAAA,sBAAA,OAAA,EAAA;AACA,EAAA,OAAA,OAAA,CAAA,OAAA,CAAA,MAAA,EAAA,GAAA,EAAA,IAAA,EAAA;AACA;AAEA,iBAAA,kBAAA,CAAA,OAAA,KAAA,KAAA;AACA,EAAA,MAAA,MAAA,GAAA,cAAA,CAAA,KAAA,EAAA,QAAA,CAAA;AAEA,EAAA,IAAA,CAAA,MAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,MAAA,IAAA,GAAA,MAAA,WAAA,CAAA,MAAA,CAAA;AACA,EAAA,IAAA,CAAA,IAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,IAAA;AACA,IAAA,OAAA,MAAA,iBAAA,IAAA,CAAA;AAAA,EACA,SAAA,KAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA,yBAAA;AAAA,MACA,OAAA,EAAA,qBAAA,CAAA,KAAA,CAAA,OAAA;AAAA,KACA,CAAA;AAAA,EACA;AACA,CAAA,CAAA;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as defineEventHandler, a as getRouterParam, c as createError,
|
|
1
|
+
import { d as defineEventHandler, a as getRouterParam, c as createError, f as getRepoById, e as discoverGitRepos, u as updateRepoGitRepos } from '../../../../nitro/nitro.mjs';
|
|
2
2
|
import 'node:http';
|
|
3
3
|
import 'node:https';
|
|
4
4
|
import 'node:events';
|
|
@@ -6,8 +6,9 @@ import 'node:buffer';
|
|
|
6
6
|
import 'node:fs';
|
|
7
7
|
import 'node:path';
|
|
8
8
|
import 'node:crypto';
|
|
9
|
-
import 'node:os';
|
|
10
9
|
import 'node:url';
|
|
10
|
+
import 'node:os';
|
|
11
|
+
import 'zod';
|
|
11
12
|
|
|
12
13
|
const refreshGitRepos_post = defineEventHandler(async (event) => {
|
|
13
14
|
const repoId = getRouterParam(event, "repoId");
|
|
@@ -17,23 +18,15 @@ const refreshGitRepos_post = defineEventHandler(async (event) => {
|
|
|
17
18
|
statusMessage: "Repository ID is required"
|
|
18
19
|
});
|
|
19
20
|
}
|
|
20
|
-
const
|
|
21
|
-
|
|
22
|
-
if (repoIndex === -1) {
|
|
21
|
+
const repo = await getRepoById(repoId);
|
|
22
|
+
if (!repo) {
|
|
23
23
|
throw createError({
|
|
24
24
|
statusCode: 404,
|
|
25
25
|
statusMessage: "Repository not found"
|
|
26
26
|
});
|
|
27
27
|
}
|
|
28
|
-
const repo = repos[repoIndex];
|
|
29
28
|
const gitRepos = await discoverGitRepos(repo.path);
|
|
30
|
-
|
|
31
|
-
repo.gitRepos = gitRepos;
|
|
32
|
-
} else {
|
|
33
|
-
delete repo.gitRepos;
|
|
34
|
-
}
|
|
35
|
-
repos[repoIndex] = repo;
|
|
36
|
-
await saveRepos(repos);
|
|
29
|
+
await updateRepoGitRepos(repo.id, gitRepos.length > 0 ? gitRepos : void 0);
|
|
37
30
|
return {
|
|
38
31
|
discovered: gitRepos.length,
|
|
39
32
|
gitRepos
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"refresh-git-repos.post.mjs","sources":["../../../../../../../server/api/repos/[repoId]/refresh-git-repos.post.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"refresh-git-repos.post.mjs","sources":["../../../../../../../server/api/repos/[repoId]/refresh-git-repos.post.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,6BAAA,kBAAA,CAAA,OAAA,KAAA,KAAA;AACA,EAAA,MAAA,MAAA,GAAA,cAAA,CAAA,KAAA,EAAA,QAAA,CAAA;AAEA,EAAA,IAAA,CAAA,MAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,MAAA,IAAA,GAAA,MAAA,WAAA,CAAA,MAAA,CAAA;AACA,EAAA,IAAA,CAAA,IAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAGA,EAAA,MAAA,QAAA,GAAA,MAAA,gBAAA,CAAA,IAAA,CAAA,IAAA,CAAA;AAEA,EAAA,MAAA,mBAAA,IAAA,CAAA,EAAA,EAAA,SAAA,MAAA,GAAA,CAAA,GAAA,WAAA,MAAA,CAAA;AAEA,EAAA,OAAA;AAAA,IACA,YAAA,QAAA,CAAA,MAAA;AAAA,IACA;AAAA,GACA;AACA,CAAA,CAAA;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"_repoId_.delete.mjs","sources":["../../../../../../server/api/repos/[repoId].delete.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"_repoId_.delete.mjs","sources":["../../../../../../server/api/repos/[repoId].delete.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAGA,wBAAA,kBAAA,CAAA,OAAA,KAAA,KAAA;AACA,EAAA,MAAA,EAAA,GAAA,cAAA,CAAA,KAAA,EAAA,QAAA,CAAA;AAEA,EAAA,IAAA,CAAA,EAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAEA,EAAA,MAAA,OAAA,GAAA,MAAA,UAAA,CAAA,EAAA,CAAA;AAEA,EAAA,IAAA,CAAA,OAAA,EAAA;AACA,IAAA,MAAA,WAAA,CAAA;AAAA,MACA,UAAA,EAAA,GAAA;AAAA,MACA,aAAA,EAAA;AAAA,KACA,CAAA;AAAA,EACA;AAGA,EAAA,MAAA,cAAA,EAAA;AAEA,EAAA,OAAA,EAAA,SAAA,IAAA,EAAA;AACA,CAAA,CAAA;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as defineEventHandler,
|
|
1
|
+
import { d as defineEventHandler, l as useRuntimeConfig, s as setHeader } from '../../nitro/nitro.mjs';
|
|
2
2
|
import { randomUUID } from 'node:crypto';
|
|
3
3
|
import 'node:http';
|
|
4
4
|
import 'node:https';
|
|
@@ -6,8 +6,9 @@ import 'node:events';
|
|
|
6
6
|
import 'node:buffer';
|
|
7
7
|
import 'node:fs';
|
|
8
8
|
import 'node:path';
|
|
9
|
-
import 'node:os';
|
|
10
9
|
import 'node:url';
|
|
10
|
+
import 'node:os';
|
|
11
|
+
import 'zod';
|
|
11
12
|
|
|
12
13
|
const SERVER_INSTANCE_ID = randomUUID();
|
|
13
14
|
const SERVER_STARTED_AT = (/* @__PURE__ */ new Date()).toISOString();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime.get.mjs","sources":["../../../../../server/api/runtime.get.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"runtime.get.mjs","sources":["../../../../../server/api/runtime.get.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,MAAA,qBAAA,UAAA,EAAA;AACA,MAAA,iBAAA,GAAA,iBAAA,IAAA,IAAA,EAAA,EAAA,WAAA,EAAA;AAEA,oBAAA,kBAAA,CAAA,CAAA,KAAA,KAAA;AACA,EAAA,MAAA,aAAA,GAAA,iBAAA,KAAA,CAAA;AAEA,EAAA,SAAA,CAAA,KAAA,EAAA,iBAAA,qCAAA,CAAA;AAEA,EAAA,OAAA;AAAA,IACA,OAAA,EAAA,cAAA,GAAA,CAAA,OAAA;AAAA,IACA,UAAA,EAAA,kBAAA;AAAA,IACA,SAAA,EAAA;AAAA,GACA;AACA,CAAA,CAAA;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { d as defineEventHandler,
|
|
2
|
-
import { i as initWatcher
|
|
1
|
+
import { d as defineEventHandler, s as setHeader, n as addChangeListener } from '../../nitro/nitro.mjs';
|
|
2
|
+
import { i as initWatcher } from '../../_/watcher.mjs';
|
|
3
3
|
import 'node:http';
|
|
4
4
|
import 'node:https';
|
|
5
5
|
import 'node:events';
|
|
@@ -7,8 +7,9 @@ import 'node:buffer';
|
|
|
7
7
|
import 'node:fs';
|
|
8
8
|
import 'node:path';
|
|
9
9
|
import 'node:crypto';
|
|
10
|
-
import 'node:os';
|
|
11
10
|
import 'node:url';
|
|
11
|
+
import 'node:os';
|
|
12
|
+
import 'zod';
|
|
12
13
|
import 'chokidar';
|
|
13
14
|
|
|
14
15
|
const watch_get = defineEventHandler(async (event) => {
|
|
@@ -22,7 +23,7 @@ const watch_get = defineEventHandler(async (event) => {
|
|
|
22
23
|
|
|
23
24
|
`;
|
|
24
25
|
controller.enqueue(new TextEncoder().encode(connectMsg));
|
|
25
|
-
const removeListener =
|
|
26
|
+
const removeListener = addChangeListener((fileEvent) => {
|
|
26
27
|
const msg = `data: ${JSON.stringify(fileEvent)}
|
|
27
28
|
|
|
28
29
|
`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"watch.get.mjs","sources":["../../../../../server/api/watch.get.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"watch.get.mjs","sources":["../../../../../server/api/watch.get.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAGA,kBAAA,kBAAA,CAAA,OAAA,KAAA,KAAA;AAEA,EAAA,MAAA,WAAA,EAAA;AAGA,EAAA,SAAA,CAAA,KAAA,EAAA,gBAAA,mBAAA,CAAA;AACA,EAAA,SAAA,CAAA,KAAA,EAAA,iBAAA,UAAA,CAAA;AACA,EAAA,SAAA,CAAA,KAAA,EAAA,cAAA,YAAA,CAAA;AAGA,EAAA,MAAA,MAAA,GAAA,IAAA,cAAA,CAAA;AAAA,IACA,MAAA,UAAA,EAAA;AAEA,MAAA,MAAA,UAAA,GAAA,SAAA,IAAA,CAAA,SAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,CAAA;;AAAA,CAAA;AACA,MAAA,UAAA,CAAA,QAAA,IAAA,WAAA,EAAA,CAAA,MAAA,CAAA,UAAA,CAAA,CAAA;AAGA,MAAA,MAAA,cAAA,GAAA,iBAAA,CAAA,CAAA,SAAA,KAAA;AACA,QAAA,MAAA,GAAA,GAAA,CAAA,MAAA,EAAA,IAAA,CAAA,SAAA,CAAA,SAAA,CAAA;;AAAA,CAAA;AACA,QAAA,IAAA;AACA,UAAA,UAAA,CAAA,QAAA,IAAA,WAAA,EAAA,CAAA,MAAA,CAAA,GAAA,CAAA,CAAA;AAAA,QACA,CAAA,CAAA,MAAA;AAEA,UAAA,cAAA,EAAA;AAAA,QACA;AAAA,MACA,CAAA,CAAA;AAGA,MAAA,KAAA,CAAA,IAAA,CAAA,GAAA,CAAA,EAAA,CAAA,OAAA,EAAA,MAAA;AACA,QAAA,cAAA,EAAA;AACA,QAAA,IAAA;AACA,UAAA,UAAA,CAAA,KAAA,EAAA;AAAA,QACA,CAAA,CAAA,MAAA;AAAA,QAEA;AAAA,MACA,CAAA,CAAA;AAGA,MAAA,MAAA,iBAAA,GAAA,YAAA,MAAA;AACA,QAAA,IAAA;AACA,UAAA,MAAA,IAAA,GAAA,CAAA;;AAAA,CAAA;AACA,UAAA,UAAA,CAAA,QAAA,IAAA,WAAA,EAAA,CAAA,MAAA,CAAA,IAAA,CAAA,CAAA;AAAA,QACA,CAAA,CAAA,MAAA;AACA,UAAA,aAAA,CAAA,iBAAA,CAAA;AAAA,QACA;AAAA,MACA,GAAA,GAAA,CAAA;AAEA,MAAA,KAAA,CAAA,IAAA,CAAA,GAAA,CAAA,EAAA,CAAA,OAAA,EAAA,MAAA;AACA,QAAA,aAAA,CAAA,iBAAA,CAAA;AAAA,MACA,CAAA,CAAA;AAAA,IACA;AAAA,GACA,CAAA;AAEA,EAAA,OAAA,IAAA,SAAA,MAAA,EAAA;AAAA,IACA,OAAA,EAAA;AAAA,MACA,cAAA,EAAA,mBAAA;AAAA,MACA,eAAA,EAAA,UAAA;AAAA,MACA,YAAA,EAAA;AAAA;AACA,GACA,CAAA;AACA,CAAA,CAAA;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createRenderer, getRequestDependencies, getPreloadLinks, getPrefetchLinks } from 'vue-bundle-renderer/runtime';
|
|
2
|
-
import {
|
|
2
|
+
import { p as joinRelativeURL, l as useRuntimeConfig, q as getResponseStatusText, t as getResponseStatus, w as defineRenderHandler, g as getQuery, c as createError, x as destr, y as getRouteRules, z as joinURL, A as useNitroApp } from '../nitro/nitro.mjs';
|
|
3
3
|
import { renderToString } from 'vue/server-renderer';
|
|
4
4
|
import { createHead as createHead$1, propsToString, renderSSRHead } from 'unhead/server';
|
|
5
5
|
import { stringify, uneval } from 'devalue';
|
package/.output/server/index.mjs
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import process from 'node:process';globalThis._importMeta_={url:import.meta.url,env:process.env};import 'node:http';
|
|
2
2
|
import 'node:https';
|
|
3
|
-
export {
|
|
3
|
+
export { Q as default } from './chunks/nitro/nitro.mjs';
|
|
4
4
|
import 'node:events';
|
|
5
5
|
import 'node:buffer';
|
|
6
6
|
import 'node:fs';
|
|
7
7
|
import 'node:path';
|
|
8
8
|
import 'node:crypto';
|
|
9
|
-
import 'node:os';
|
|
10
9
|
import 'node:url';
|
|
10
|
+
import 'node:os';
|
|
11
|
+
import 'zod';
|
|
11
12
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":[],"names":[],"mappings":";;;;;;;;;;"}
|