opencode-gitlab-dap 1.11.0 → 1.12.1
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/dist/index.cjs +13 -7
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +13 -7
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -3604,7 +3604,8 @@ var MEMORY_TYPES = [
|
|
|
3604
3604
|
"architecture",
|
|
3605
3605
|
"conventions",
|
|
3606
3606
|
"troubleshooting",
|
|
3607
|
-
"people-and-contexts"
|
|
3607
|
+
"people-and-contexts",
|
|
3608
|
+
"plans"
|
|
3608
3609
|
];
|
|
3609
3610
|
var MEMORY_DIRS = {
|
|
3610
3611
|
all: MEMORY_TYPES.map((t) => `${PREFIX}/memory/${t}`),
|
|
@@ -3618,7 +3619,8 @@ var RECORD_TYPES = [
|
|
|
3618
3619
|
"architecture",
|
|
3619
3620
|
"convention",
|
|
3620
3621
|
"troubleshooting",
|
|
3621
|
-
"people"
|
|
3622
|
+
"people",
|
|
3623
|
+
"plan"
|
|
3622
3624
|
];
|
|
3623
3625
|
var RECORD_DIR = {
|
|
3624
3626
|
fact: `${PREFIX}/memory/facts`,
|
|
@@ -3627,14 +3629,18 @@ var RECORD_DIR = {
|
|
|
3627
3629
|
architecture: `${PREFIX}/memory/architecture`,
|
|
3628
3630
|
convention: `${PREFIX}/memory/conventions`,
|
|
3629
3631
|
troubleshooting: `${PREFIX}/memory/troubleshooting`,
|
|
3630
|
-
people: `${PREFIX}/memory/people-and-contexts
|
|
3632
|
+
people: `${PREFIX}/memory/people-and-contexts`,
|
|
3633
|
+
plan: `${PREFIX}/memory/plans`
|
|
3631
3634
|
};
|
|
3632
3635
|
var PROJECT_ID_DESC = 'FULL project path with namespace (e.g., "gitlab-org/gitlab"). Must contain a slash. Never use just the project name.';
|
|
3633
3636
|
function today() {
|
|
3634
3637
|
return (/* @__PURE__ */ new Date()).toISOString().slice(0, 10);
|
|
3635
3638
|
}
|
|
3639
|
+
function shortHash() {
|
|
3640
|
+
return Math.random().toString(36).slice(2, 8);
|
|
3641
|
+
}
|
|
3636
3642
|
function slugify(text) {
|
|
3637
|
-
return text.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/(^-|-$)/g, "").slice(0,
|
|
3643
|
+
return text.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/(^-|-$)/g, "").slice(0, 50);
|
|
3638
3644
|
}
|
|
3639
3645
|
function titleFromContent(content) {
|
|
3640
3646
|
const first = content.split("\n")[0].replace(/^[#*\->\s]+/, "").trim();
|
|
@@ -3707,7 +3713,7 @@ ${entries}`
|
|
|
3707
3713
|
}
|
|
3708
3714
|
}),
|
|
3709
3715
|
gitlab_memory_record: (0, import_plugin5.tool)({
|
|
3710
|
-
description: "Record knowledge in project memory. Each record creates its own page \u2014 safe for parallel writes.\nTypes:\n fact \u2014 stable truths (tech stack, dependencies, deploy targets, project metadata)\n decision \u2014 architectural choices with reasoning (why X over Y)\n pattern \u2014 recurring observations that may evolve into skills\n architecture \u2014 system design, module structure, data flow, key abstractions\n convention \u2014 coding standards, naming patterns, review process, commit conventions\n troubleshooting \u2014 known issues, workarounds, debugging tips, common errors\n people \u2014 team members, roles, ownership areas, contact context",
|
|
3716
|
+
description: "Record knowledge in project memory. Each record creates its own page \u2014 safe for parallel writes.\nTypes:\n fact \u2014 stable truths (tech stack, dependencies, deploy targets, project metadata)\n decision \u2014 architectural choices with reasoning (why X over Y)\n pattern \u2014 recurring observations that may evolve into skills\n architecture \u2014 system design, module structure, data flow, key abstractions\n convention \u2014 coding standards, naming patterns, review process, commit conventions\n troubleshooting \u2014 known issues, workarounds, debugging tips, common errors\n people \u2014 team members, roles, ownership areas, contact context\n plan \u2014 implementation plans, feature designs, task breakdowns, roadmap items",
|
|
3711
3717
|
args: {
|
|
3712
3718
|
project_id: z5.string().describe(PROJECT_ID_DESC),
|
|
3713
3719
|
type: z5.enum([...RECORD_TYPES]).describe("Type of knowledge to record"),
|
|
@@ -3722,7 +3728,7 @@ ${entries}`
|
|
|
3722
3728
|
if (!dir) return `Unknown memory type: ${args.type}`;
|
|
3723
3729
|
const date = today();
|
|
3724
3730
|
const title = titleFromContent(args.content);
|
|
3725
|
-
const slug = `${dir}/${date}-${slugify(title)}`;
|
|
3731
|
+
const slug = `${dir}/${date}-${slugify(title)}-${shortHash()}`;
|
|
3726
3732
|
const header = `*Recorded: ${date} | Type: ${args.type}*
|
|
3727
3733
|
|
|
3728
3734
|
`;
|
|
@@ -3927,7 +3933,7 @@ ${e.content}`).join("\n\n---\n\n");
|
|
|
3927
3933
|
const auth = authAndValidate(args.project_id);
|
|
3928
3934
|
const { scope, id } = resolveScope(args);
|
|
3929
3935
|
const date = today();
|
|
3930
|
-
const slug = `${PREFIX}/memory/sessions/${date}-${slugify(args.title)}`;
|
|
3936
|
+
const slug = `${PREFIX}/memory/sessions/${date}-${slugify(args.title)}-${shortHash()}`;
|
|
3931
3937
|
try {
|
|
3932
3938
|
await createWikiPage(auth.instanceUrl, auth.token, scope, id, slug, args.summary);
|
|
3933
3939
|
return `Session logged: ${slug}`;
|