nomoreide 0.1.52 → 0.1.54
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/core/git-actions.d.ts +8 -0
- package/dist/core/git-actions.js +23 -0
- package/dist/core/git-actions.js.map +1 -1
- package/dist/core/workflows.d.ts +34 -10
- package/dist/core/workflows.js +29 -3
- package/dist/core/workflows.js.map +1 -1
- package/dist/web/client/assets/{code-editor-_ve7fiz7.js → code-editor-dsjVJ-4Z.js} +1 -1
- package/dist/web/client/assets/{index-CLEWYNCX.js → index-CpAg7ECo.js} +137 -137
- package/dist/web/client/assets/index-D4fn2UZ8.css +1 -0
- package/dist/web/client/index.html +2 -2
- package/dist/web/routes/git-routes.js +10 -0
- package/dist/web/routes/git-routes.js.map +1 -1
- package/package.json +1 -1
- package/dist/web/client/assets/index-7b_XjCVh.css +0 -1
|
@@ -6,6 +6,10 @@ export interface PushResult {
|
|
|
6
6
|
/** True when an upstream had to be set (first push of a new branch). */
|
|
7
7
|
setUpstream: boolean;
|
|
8
8
|
}
|
|
9
|
+
export interface CheckoutDefaultAndPullResult {
|
|
10
|
+
output: string;
|
|
11
|
+
branch: string;
|
|
12
|
+
}
|
|
9
13
|
/**
|
|
10
14
|
* Write-capable Git operations, kept deliberately separate from the read-safe
|
|
11
15
|
* {@link GitManager}. These reach outward (push) or move refs, so they live in
|
|
@@ -26,5 +30,9 @@ export declare class GitActions {
|
|
|
26
30
|
push(options?: {
|
|
27
31
|
remote?: string;
|
|
28
32
|
}): Promise<PushResult>;
|
|
33
|
+
checkoutDefaultAndPull(options?: {
|
|
34
|
+
remote?: string;
|
|
35
|
+
}): Promise<CheckoutDefaultAndPullResult>;
|
|
36
|
+
private defaultBranch;
|
|
29
37
|
private git;
|
|
30
38
|
}
|
package/dist/core/git-actions.js
CHANGED
|
@@ -38,6 +38,29 @@ export class GitActions {
|
|
|
38
38
|
: ["push"];
|
|
39
39
|
return { output: await this.git(args), branch, setUpstream };
|
|
40
40
|
}
|
|
41
|
+
async checkoutDefaultAndPull(options = {}) {
|
|
42
|
+
const remote = options.remote ?? "origin";
|
|
43
|
+
const branch = await this.defaultBranch(remote);
|
|
44
|
+
const switchOutput = await this.git(["switch", branch]);
|
|
45
|
+
const pullOutput = await this.git(["pull", "--ff-only"]);
|
|
46
|
+
return {
|
|
47
|
+
branch,
|
|
48
|
+
output: [`Switched to ${branch}.`, switchOutput, pullOutput].filter(Boolean).join("\n").trim(),
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
async defaultBranch(remote) {
|
|
52
|
+
const remoteHead = (await this.git(["symbolic-ref", "--short", `refs/remotes/${remote}/HEAD`]).catch(() => "")).trim();
|
|
53
|
+
const fromRemoteHead = remoteHead.startsWith(`${remote}/`) ? remoteHead.slice(remote.length + 1) : remoteHead;
|
|
54
|
+
if (fromRemoteHead)
|
|
55
|
+
return fromRemoteHead;
|
|
56
|
+
const branches = await this.git(["branch", "--format=%(refname:short)"]);
|
|
57
|
+
const names = branches.split("\n").map((line) => line.trim()).filter(Boolean);
|
|
58
|
+
if (names.includes("main"))
|
|
59
|
+
return "main";
|
|
60
|
+
if (names.includes("master"))
|
|
61
|
+
return "master";
|
|
62
|
+
throw new Error(`Could not determine default branch for ${remote}.`);
|
|
63
|
+
}
|
|
41
64
|
async git(args) {
|
|
42
65
|
try {
|
|
43
66
|
const { stdout, stderr } = await execFileAsync("git", args, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"git-actions.js","sourceRoot":"","sources":["../../src/core/git-actions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAEtC,MAAM,aAAa,GAAG,SAAS,CAAC,QAAQ,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"git-actions.js","sourceRoot":"","sources":["../../src/core/git-actions.ts"],"names":[],"mappings":"AAAA,OAA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E,IAAI,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC;YAAE,OAAO,MAAM,CAAC;QAC1C,IAAI,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC;YAAE,OAAO,QAAQ,CAAC;QAC9C,MAAM,IAAI,KAAK,CAAC,0CAA0C,MAAM,GAAG,CAAC,CAAC;IACvE,CAAC;IAEO,KAAK,CAAC,GAAG,CAAC,IAAc;QAC9B,IAAI,CAAC;YACH,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,MAAM,aAAa,CAAC,KAAK,EAAE,IAAI,EAAE;gBAC1D,GAAG,EAAE,IAAI,CAAC,GAAG;gBACb,SAAS,EAAE,EAAE,GAAG,IAAI,GAAG,IAAI;aAC5B,CAAC,CAAC;YACH,OAAO,MAAM,IAAI,MAAM,CAAC;QAC1B,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,IAAI,KAAK,YAAY,KAAK,EAAE,CAAC;gBAC3B,MAAM,WAAW,GAAG,KAAqD,CAAC;gBAC1E,MAAM,IAAI,KAAK,CACb,CAAC,WAAW,CAAC,MAAM,IAAI,WAAW,CAAC,MAAM,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,IAAI,EAAE,CACnE,CAAC;YACJ,CAAC;YACD,MAAM,KAAK,CAAC;QACd,CAAC;IACH,CAAC;CACF"}
|
package/dist/core/workflows.d.ts
CHANGED
|
@@ -25,19 +25,20 @@ export declare const workflowStepSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
25
25
|
* zero agent tokens. `assert-pr-branch` blocks on default branches before PR
|
|
26
26
|
* workflows can commit; `commit` stages everything and commits with a
|
|
27
27
|
* generated message (no diff reading, no quality analysis); `push` pushes
|
|
28
|
-
* the branch
|
|
28
|
+
* the branch; `checkout-default-and-pull` returns to the default branch after
|
|
29
|
+
* a PR workflow and fast-forward pulls it.
|
|
29
30
|
*/
|
|
30
|
-
op: z.ZodEnum<["push", "commit", "assert-pr-branch"]>;
|
|
31
|
+
op: z.ZodEnum<["push", "commit", "assert-pr-branch", "checkout-default-and-pull"]>;
|
|
31
32
|
}, "strip", z.ZodTypeAny, {
|
|
32
33
|
kind: "action";
|
|
33
34
|
id: string;
|
|
34
35
|
title: string;
|
|
35
|
-
op: "push" | "commit" | "assert-pr-branch";
|
|
36
|
+
op: "push" | "commit" | "assert-pr-branch" | "checkout-default-and-pull";
|
|
36
37
|
}, {
|
|
37
38
|
kind: "action";
|
|
38
39
|
id: string;
|
|
39
40
|
title: string;
|
|
40
|
-
op: "push" | "commit" | "assert-pr-branch";
|
|
41
|
+
op: "push" | "commit" | "assert-pr-branch" | "checkout-default-and-pull";
|
|
41
42
|
}>, z.ZodObject<{
|
|
42
43
|
kind: z.ZodLiteral<"agent">;
|
|
43
44
|
id: z.ZodString;
|
|
@@ -61,6 +62,14 @@ export declare const workflowStepSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
61
62
|
plugins?: string[] | undefined;
|
|
62
63
|
hooks?: string[] | undefined;
|
|
63
64
|
}>>;
|
|
65
|
+
/**
|
|
66
|
+
* Run this step in a fresh, one-shot agent session instead of resuming the
|
|
67
|
+
* dock conversation. Much cheaper — the model isn't re-fed every earlier
|
|
68
|
+
* step's transcript and tool output — but the step gets no shared memory, so
|
|
69
|
+
* only set it on self-contained steps (e.g. drafting a commit message, not
|
|
70
|
+
* "merge the PR you just opened").
|
|
71
|
+
*/
|
|
72
|
+
isolated: z.ZodOptional<z.ZodBoolean>;
|
|
64
73
|
/**
|
|
65
74
|
* Real-state check run after the agent's turn before advancing:
|
|
66
75
|
* - `committed` — the working tree is clean (changes were committed).
|
|
@@ -78,6 +87,7 @@ export declare const workflowStepSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
78
87
|
plugins?: string[] | undefined;
|
|
79
88
|
hooks?: string[] | undefined;
|
|
80
89
|
} | undefined;
|
|
90
|
+
isolated?: boolean | undefined;
|
|
81
91
|
verify?: "committed" | "pushed" | undefined;
|
|
82
92
|
}, {
|
|
83
93
|
kind: "agent";
|
|
@@ -90,6 +100,7 @@ export declare const workflowStepSchema: z.ZodDiscriminatedUnion<"kind", [z.ZodO
|
|
|
90
100
|
plugins?: string[] | undefined;
|
|
91
101
|
hooks?: string[] | undefined;
|
|
92
102
|
} | undefined;
|
|
103
|
+
isolated?: boolean | undefined;
|
|
93
104
|
verify?: "committed" | "pushed" | undefined;
|
|
94
105
|
}>, z.ZodObject<{
|
|
95
106
|
kind: z.ZodLiteral<"gate">;
|
|
@@ -123,19 +134,20 @@ export declare const workflowSchema: z.ZodObject<{
|
|
|
123
134
|
* zero agent tokens. `assert-pr-branch` blocks on default branches before PR
|
|
124
135
|
* workflows can commit; `commit` stages everything and commits with a
|
|
125
136
|
* generated message (no diff reading, no quality analysis); `push` pushes
|
|
126
|
-
* the branch
|
|
137
|
+
* the branch; `checkout-default-and-pull` returns to the default branch after
|
|
138
|
+
* a PR workflow and fast-forward pulls it.
|
|
127
139
|
*/
|
|
128
|
-
op: z.ZodEnum<["push", "commit", "assert-pr-branch"]>;
|
|
140
|
+
op: z.ZodEnum<["push", "commit", "assert-pr-branch", "checkout-default-and-pull"]>;
|
|
129
141
|
}, "strip", z.ZodTypeAny, {
|
|
130
142
|
kind: "action";
|
|
131
143
|
id: string;
|
|
132
144
|
title: string;
|
|
133
|
-
op: "push" | "commit" | "assert-pr-branch";
|
|
145
|
+
op: "push" | "commit" | "assert-pr-branch" | "checkout-default-and-pull";
|
|
134
146
|
}, {
|
|
135
147
|
kind: "action";
|
|
136
148
|
id: string;
|
|
137
149
|
title: string;
|
|
138
|
-
op: "push" | "commit" | "assert-pr-branch";
|
|
150
|
+
op: "push" | "commit" | "assert-pr-branch" | "checkout-default-and-pull";
|
|
139
151
|
}>, z.ZodObject<{
|
|
140
152
|
kind: z.ZodLiteral<"agent">;
|
|
141
153
|
id: z.ZodString;
|
|
@@ -159,6 +171,14 @@ export declare const workflowSchema: z.ZodObject<{
|
|
|
159
171
|
plugins?: string[] | undefined;
|
|
160
172
|
hooks?: string[] | undefined;
|
|
161
173
|
}>>;
|
|
174
|
+
/**
|
|
175
|
+
* Run this step in a fresh, one-shot agent session instead of resuming the
|
|
176
|
+
* dock conversation. Much cheaper — the model isn't re-fed every earlier
|
|
177
|
+
* step's transcript and tool output — but the step gets no shared memory, so
|
|
178
|
+
* only set it on self-contained steps (e.g. drafting a commit message, not
|
|
179
|
+
* "merge the PR you just opened").
|
|
180
|
+
*/
|
|
181
|
+
isolated: z.ZodOptional<z.ZodBoolean>;
|
|
162
182
|
/**
|
|
163
183
|
* Real-state check run after the agent's turn before advancing:
|
|
164
184
|
* - `committed` — the working tree is clean (changes were committed).
|
|
@@ -176,6 +196,7 @@ export declare const workflowSchema: z.ZodObject<{
|
|
|
176
196
|
plugins?: string[] | undefined;
|
|
177
197
|
hooks?: string[] | undefined;
|
|
178
198
|
} | undefined;
|
|
199
|
+
isolated?: boolean | undefined;
|
|
179
200
|
verify?: "committed" | "pushed" | undefined;
|
|
180
201
|
}, {
|
|
181
202
|
kind: "agent";
|
|
@@ -188,6 +209,7 @@ export declare const workflowSchema: z.ZodObject<{
|
|
|
188
209
|
plugins?: string[] | undefined;
|
|
189
210
|
hooks?: string[] | undefined;
|
|
190
211
|
} | undefined;
|
|
212
|
+
isolated?: boolean | undefined;
|
|
191
213
|
verify?: "committed" | "pushed" | undefined;
|
|
192
214
|
}>, z.ZodObject<{
|
|
193
215
|
kind: z.ZodLiteral<"gate">;
|
|
@@ -213,7 +235,7 @@ export declare const workflowSchema: z.ZodObject<{
|
|
|
213
235
|
kind: "action";
|
|
214
236
|
id: string;
|
|
215
237
|
title: string;
|
|
216
|
-
op: "push" | "commit" | "assert-pr-branch";
|
|
238
|
+
op: "push" | "commit" | "assert-pr-branch" | "checkout-default-and-pull";
|
|
217
239
|
} | {
|
|
218
240
|
kind: "agent";
|
|
219
241
|
id: string;
|
|
@@ -225,6 +247,7 @@ export declare const workflowSchema: z.ZodObject<{
|
|
|
225
247
|
plugins?: string[] | undefined;
|
|
226
248
|
hooks?: string[] | undefined;
|
|
227
249
|
} | undefined;
|
|
250
|
+
isolated?: boolean | undefined;
|
|
228
251
|
verify?: "committed" | "pushed" | undefined;
|
|
229
252
|
} | {
|
|
230
253
|
message: string;
|
|
@@ -241,7 +264,7 @@ export declare const workflowSchema: z.ZodObject<{
|
|
|
241
264
|
kind: "action";
|
|
242
265
|
id: string;
|
|
243
266
|
title: string;
|
|
244
|
-
op: "push" | "commit" | "assert-pr-branch";
|
|
267
|
+
op: "push" | "commit" | "assert-pr-branch" | "checkout-default-and-pull";
|
|
245
268
|
} | {
|
|
246
269
|
kind: "agent";
|
|
247
270
|
id: string;
|
|
@@ -253,6 +276,7 @@ export declare const workflowSchema: z.ZodObject<{
|
|
|
253
276
|
plugins?: string[] | undefined;
|
|
254
277
|
hooks?: string[] | undefined;
|
|
255
278
|
} | undefined;
|
|
279
|
+
isolated?: boolean | undefined;
|
|
256
280
|
verify?: "committed" | "pushed" | undefined;
|
|
257
281
|
} | {
|
|
258
282
|
message: string;
|
package/dist/core/workflows.js
CHANGED
|
@@ -32,9 +32,10 @@ export const workflowStepSchema = z.discriminatedUnion("kind", [
|
|
|
32
32
|
* zero agent tokens. `assert-pr-branch` blocks on default branches before PR
|
|
33
33
|
* workflows can commit; `commit` stages everything and commits with a
|
|
34
34
|
* generated message (no diff reading, no quality analysis); `push` pushes
|
|
35
|
-
* the branch
|
|
35
|
+
* the branch; `checkout-default-and-pull` returns to the default branch after
|
|
36
|
+
* a PR workflow and fast-forward pulls it.
|
|
36
37
|
*/
|
|
37
|
-
op: z.enum(["push", "commit", "assert-pr-branch"]),
|
|
38
|
+
op: z.enum(["push", "commit", "assert-pr-branch", "checkout-default-and-pull"]),
|
|
38
39
|
}),
|
|
39
40
|
z.object({
|
|
40
41
|
kind: z.literal("agent"),
|
|
@@ -44,6 +45,14 @@ export const workflowStepSchema = z.discriminatedUnion("kind", [
|
|
|
44
45
|
prompt: z.string().min(1),
|
|
45
46
|
/** Optional user-selected capabilities the runner adds as prompt guidance. */
|
|
46
47
|
capabilities: workflowCapabilitiesSchema.optional(),
|
|
48
|
+
/**
|
|
49
|
+
* Run this step in a fresh, one-shot agent session instead of resuming the
|
|
50
|
+
* dock conversation. Much cheaper — the model isn't re-fed every earlier
|
|
51
|
+
* step's transcript and tool output — but the step gets no shared memory, so
|
|
52
|
+
* only set it on self-contained steps (e.g. drafting a commit message, not
|
|
53
|
+
* "merge the PR you just opened").
|
|
54
|
+
*/
|
|
55
|
+
isolated: z.boolean().optional(),
|
|
47
56
|
/**
|
|
48
57
|
* Real-state check run after the agent's turn before advancing:
|
|
49
58
|
* - `committed` — the working tree is clean (changes were committed).
|
|
@@ -81,6 +90,10 @@ const COMMIT_MESSAGE_STEP = {
|
|
|
81
90
|
kind: "agent",
|
|
82
91
|
id: "commit-message",
|
|
83
92
|
title: "Generate commit message",
|
|
93
|
+
// Self-contained: it stages, reads its own staged diff, and replies with just
|
|
94
|
+
// the message (which the commit action consumes). No later step needs its
|
|
95
|
+
// session, so run it isolated to avoid re-feeding the dock transcript.
|
|
96
|
+
isolated: true,
|
|
84
97
|
prompt: "Stage my changes with `nomoreide_git_stage` (skip anything that looks like a secret, e.g. `.env`), inspect the staged diff once with `nomoreide_git_staged_diff`, then write one conventional-commit message — a `<type>: concise title` line (feat/fix/refactor/chore/docs/test) plus a few short bullets of what changed. Do NOT commit. Reply with ONLY the commit message you recommend.",
|
|
85
98
|
};
|
|
86
99
|
const COMMIT_ACTION_STEP = {
|
|
@@ -95,6 +108,12 @@ const ASSERT_PR_BRANCH_STEP = {
|
|
|
95
108
|
title: "Check PR branch",
|
|
96
109
|
op: "assert-pr-branch",
|
|
97
110
|
};
|
|
111
|
+
const CHECKOUT_DEFAULT_AND_PULL_STEP = {
|
|
112
|
+
kind: "action",
|
|
113
|
+
id: "checkout-default-and-pull",
|
|
114
|
+
title: "Return to default branch",
|
|
115
|
+
op: "checkout-default-and-pull",
|
|
116
|
+
};
|
|
98
117
|
/**
|
|
99
118
|
* The Phase-1 starter set. These are plain data (not hardcoded UI), so the same
|
|
100
119
|
* structure a user authors later can be forked from one of these.
|
|
@@ -129,6 +148,9 @@ export const BUILTIN_WORKFLOWS = [
|
|
|
129
148
|
kind: "agent",
|
|
130
149
|
id: "open-pr",
|
|
131
150
|
title: "Open a PR",
|
|
151
|
+
// Self-contained: gathers its own commit list, so it needs no prior
|
|
152
|
+
// session — run it isolated. The merge step below finds the PR itself.
|
|
153
|
+
isolated: true,
|
|
132
154
|
prompt: "Open a PR for the current branch into `main` using the `nomoreide_github_create_pr` tool. Title = the latest commit subject; for the body, list the commits via `nomoreide_git_log`. Do NOT read file diffs. Reply with just the PR number and URL.",
|
|
133
155
|
},
|
|
134
156
|
{ kind: "gate", id: "gate-merge", title: "Approve merge", message: "Squash-merge the pull request?" },
|
|
@@ -136,8 +158,12 @@ export const BUILTIN_WORKFLOWS = [
|
|
|
136
158
|
kind: "agent",
|
|
137
159
|
id: "merge",
|
|
138
160
|
title: "Squash-merge",
|
|
139
|
-
|
|
161
|
+
// Finds the PR by branch rather than relying on the open-pr step's
|
|
162
|
+
// session, so it can run isolated too.
|
|
163
|
+
isolated: true,
|
|
164
|
+
prompt: "Squash-merge the open pull request for the current branch. First call `nomoreide_git_status` for the branch name, then `nomoreide_github_list_prs` to find its open PR, then merge it with `nomoreide_github_merge_pr`. Don't analyze anything else — just find it and merge. Reply with one line.",
|
|
140
165
|
},
|
|
166
|
+
CHECKOUT_DEFAULT_AND_PULL_STEP,
|
|
141
167
|
],
|
|
142
168
|
},
|
|
143
169
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workflows.js","sourceRoot":"","sources":["../../src/core/workflows.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,0BAA0B,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,MAAM,EAAE,CAAC,CAAC,KAAK,CA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