copilot-operator 0.1.84 → 0.1.85

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 (60) hide show
  1. package/dist/src/api/operator.controller.js +90 -0
  2. package/dist/src/api/operator.service.js +270 -30
  3. package/dist/src/config/schema.js +17 -0
  4. package/dist/src/orchestrator/cardText.js +91 -0
  5. package/dist/src/orchestrator/kerriganRunner.js +912 -0
  6. package/dist/src/orchestrator/leadRunner.js +22 -14
  7. package/dist/src/orchestrator/planMode.js +6 -4
  8. package/dist/src/orchestrator/taskRunner.js +42 -14
  9. package/dist/src/plan/kerrigan.js +109 -4
  10. package/dist/src/plan/systemGuide.js +194 -2
  11. package/dist/src/protocol/kerriganSchema.js +175 -0
  12. package/dist/src/session/store.js +9 -0
  13. package/dist/src/vcs/git.js +72 -2
  14. package/dist/src/vcs/operatorGit.js +409 -0
  15. package/dist/web/404.html +2 -2
  16. package/dist/web/_next/static/chunks/1077.06fe73b2c16f8f49.js +1 -0
  17. package/dist/web/_next/static/chunks/1548.b38c5d8d00ab2a72.js +1 -0
  18. package/dist/web/_next/static/chunks/{2163.2af0979126ae613a.js → 2163.ba933c9a506302ca.js} +1 -1
  19. package/dist/web/_next/static/chunks/714.575273a189d030fe.js +1 -0
  20. package/dist/web/_next/static/chunks/7220.988dfd28e00f407c.js +1 -0
  21. package/dist/web/_next/static/chunks/7921-65dd56d87144bd44.js +1 -0
  22. package/dist/web/_next/static/chunks/8124-1dba8babfcfbc6e2.js +1 -0
  23. package/dist/web/_next/static/chunks/8584.2221587201bc2fa2.js +1 -0
  24. package/dist/web/_next/static/chunks/9067.8d94a08830c3d1da.js +1 -0
  25. package/dist/web/_next/static/chunks/9747.8671194406acd839.js +1 -0
  26. package/dist/web/_next/static/chunks/app/layout-127e5af1ebf21876.js +1 -0
  27. package/dist/web/_next/static/chunks/app/page-76139370c7ca3715.js +1 -0
  28. package/dist/web/_next/static/chunks/app/settings/page-116da78c83f0c5c9.js +1 -0
  29. package/dist/web/_next/static/chunks/webpack-13ccb80d7b7094ca.js +1 -0
  30. package/dist/web/_next/static/css/6e2b8656501f0dd7.css +1 -0
  31. package/dist/web/defaults.html +2 -2
  32. package/dist/web/defaults.txt +8 -8
  33. package/dist/web/index.html +3 -3
  34. package/dist/web/index.txt +9 -9
  35. package/dist/web/queue.html +2 -2
  36. package/dist/web/queue.txt +9 -9
  37. package/dist/web/settings.html +2 -2
  38. package/dist/web/settings.txt +9 -9
  39. package/dist/web/system.html +2 -2
  40. package/dist/web/system.txt +9 -9
  41. package/package.json +175 -173
  42. package/prompts/kerrigan1.md +169 -0
  43. package/prompts/lead1.md +4 -1
  44. package/prompts/level1.md +8 -1
  45. package/dist/web/_next/static/chunks/1077.e0136d293069ccb8.js +0 -1
  46. package/dist/web/_next/static/chunks/1548.5cc0c57b00c2e44f.js +0 -1
  47. package/dist/web/_next/static/chunks/714.410e2b61aa8c72b7.js +0 -1
  48. package/dist/web/_next/static/chunks/7220.2c4e5173a060769f.js +0 -1
  49. package/dist/web/_next/static/chunks/7921-3d21f385338afdf9.js +0 -1
  50. package/dist/web/_next/static/chunks/8124-1dc34be1646970a8.js +0 -1
  51. package/dist/web/_next/static/chunks/8584.61650a59d2bfa54d.js +0 -1
  52. package/dist/web/_next/static/chunks/9067.553056fc9b6cf80e.js +0 -1
  53. package/dist/web/_next/static/chunks/9747.d5826524bf4b714d.js +0 -1
  54. package/dist/web/_next/static/chunks/app/layout-b8a1e0075a48b025.js +0 -1
  55. package/dist/web/_next/static/chunks/app/page-13147b69cf336831.js +0 -1
  56. package/dist/web/_next/static/chunks/app/settings/page-e3909ef6c2d8e321.js +0 -1
  57. package/dist/web/_next/static/chunks/webpack-19a2d7161f23b21d.js +0 -1
  58. package/dist/web/_next/static/css/f152f27d6afce55c.css +0 -1
  59. /package/dist/web/_next/static/{WU_J4Ke1d3xVfpW2acqqf → aCQe1FDhYTj4zGeI5ueVq}/_buildManifest.js +0 -0
  60. /package/dist/web/_next/static/{WU_J4Ke1d3xVfpW2acqqf → aCQe1FDhYTj4zGeI5ueVq}/_ssgManifest.js +0 -0
@@ -0,0 +1,409 @@
1
+ /**
2
+ * The operator's own git in the open folder, from the Git view (operator, 2026-11-11: "add committing and pushing; a
3
+ * commit may not go through, and the operator must be able to see why"): files staged and unstaged, a commit, a push.
4
+ *
5
+ * On the real git, as the operator's terminal or VS Code would run it — no git rewritten in JavaScript, which has no
6
+ * hooks, no SSH and no credential manager — so the operator's name, their signing, their credential manager and the
7
+ * project's hooks all work as they do there. What git prints is the operator's to read, all of it: the view follows
8
+ * it as it comes, and a commit or push that did not go through says why in a sentence too (`GitCause`), with git's own
9
+ * words under it.
10
+ *
11
+ * The project's hooks (operator, 2026-11-11: "yes, unless a hook was changed"): every other git of the bot runs with
12
+ * hooks pointed at nowhere (`SAFE_GIT`), since a hook is code in the repository and the chat's steps write in it. A
13
+ * commit and a push of the operator's run them, as git would — pre-commit and commit-msg checks, Git LFS's pre-push —
14
+ * once each hook file that would run is found to be the project's own (`hooksFor`): outside the project's folder (in
15
+ * `.git`, where the chat may not write, or a hooks folder of the operator's elsewhere), or committed, unchanged since,
16
+ * and not last committed by the bot. Any other — not committed, changed since its commit, committed by the bot — is
17
+ * named to the operator with why, and nothing runs until they say: without the hooks, run them all the same (remembered
18
+ * for that file as it is now, `TrustedHooks`), or not at all.
19
+ *
20
+ * Nothing is forced and nothing is rewritten: no `--force`, no `--amend`, no reset. A push goes to the branch's
21
+ * upstream, or publishes the branch on the remote under its own name when it has none.
22
+ */
23
+ import { createHash } from 'node:crypto';
24
+ import { existsSync, readdirSync, readFileSync, statSync } from 'node:fs';
25
+ import { mkdir, readFile, writeFile } from 'node:fs/promises';
26
+ import { basename, dirname, isAbsolute, join, relative, resolve } from 'node:path';
27
+ import { git, gitLive, RUNNER_EMAIL } from './git.js';
28
+ import { askpassProgram, closePasswordWindows, operatorFetchEnv, passwordWindowOpen } from './remoteAuth.js';
29
+ import { workspaceGit } from '../session/workspaceGit.js';
30
+ const MINUTES = 60_000;
31
+ /** Long enough for a project's pre-commit checks or a big push; the view shows every line meanwhile. */
32
+ const OP_TIMEOUT_MS = 15 * MINUTES;
33
+ /** The hooks a commit may run, and a push. Git runs a hook only by its exact name. */
34
+ const COMMIT_HOOKS = ['pre-commit', 'prepare-commit-msg', 'commit-msg', 'post-commit', 'reference-transaction', 'post-index-change'];
35
+ const PUSH_HOOKS = ['pre-push', 'reference-transaction'];
36
+ /** Every name git runs a hook by (githooks(5)): a file of another name in the folder is a helper the hooks may read. */
37
+ const HOOK_NAMES = new Set([
38
+ 'applypatch-msg', 'pre-applypatch', 'post-applypatch', 'pre-commit', 'pre-merge-commit', 'prepare-commit-msg', 'commit-msg', 'post-commit',
39
+ 'pre-rebase', 'post-checkout', 'post-merge', 'pre-push', 'pre-receive', 'update', 'proc-receive', 'post-receive', 'post-update',
40
+ 'reference-transaction', 'push-to-checkout', 'pre-auto-gc', 'post-rewrite', 'sendemail-validate', 'fsmonitor-watchman', 'post-index-change',
41
+ ]);
42
+ const isFile = (p) => {
43
+ try {
44
+ return statSync(p).isFile();
45
+ }
46
+ catch {
47
+ return false;
48
+ }
49
+ };
50
+ const sha256 = (p) => {
51
+ try {
52
+ return createHash('sha256').update(readFileSync(p)).digest('hex');
53
+ }
54
+ catch {
55
+ return '';
56
+ }
57
+ };
58
+ const slash = (p) => p.replace(/\\/g, '/');
59
+ /** A repository as a key: its top folder, absolute, forward slashes, case folded as Windows does. */
60
+ const repoKey = (top) => slash(resolve(top)).replace(/\/+$/, '').toLowerCase();
61
+ /**
62
+ * The hook files the operator said to run although they were not the project's own, each as it was then (its hash):
63
+ * a file changed since is asked about again. Kept in the bot's records, one list per repository.
64
+ */
65
+ export class TrustedHooks {
66
+ file;
67
+ constructor(file) {
68
+ this.file = file;
69
+ }
70
+ async read() {
71
+ try {
72
+ const data = JSON.parse(await readFile(this.file, 'utf8'));
73
+ return data && typeof data === 'object' ? data : {};
74
+ }
75
+ catch {
76
+ return {};
77
+ }
78
+ }
79
+ async has(top, path, sha) {
80
+ return !!sha && (await this.read())[repoKey(top)]?.[path] === sha;
81
+ }
82
+ async add(top, hooks) {
83
+ if (hooks.length === 0)
84
+ return;
85
+ const all = await this.read();
86
+ const mine = { ...(all[repoKey(top)] ?? {}) };
87
+ for (const h of hooks)
88
+ mine[h.path] = h.sha;
89
+ all[repoKey(top)] = mine;
90
+ await mkdir(dirname(this.file), { recursive: true });
91
+ await writeFile(this.file, `${JSON.stringify(all, null, 2)}\n`, 'utf8');
92
+ }
93
+ }
94
+ /** The repository's top folder, or null when the folder is not in one. */
95
+ async function topOf(dir) {
96
+ if (!dir || !existsSync(dir))
97
+ return null;
98
+ const inside = await git(dir, ['rev-parse', '--is-inside-work-tree']);
99
+ if (!inside.ok || inside.stdout !== 'true')
100
+ return null;
101
+ const top = await git(dir, ['rev-parse', '--show-toplevel']);
102
+ return top.ok && top.stdout ? resolve(top.stdout) : null;
103
+ }
104
+ /** Why a hook file is not the project's own, or null when it is (see the head of this file). */
105
+ async function notOwn(top, full) {
106
+ const rel = relative(top, full);
107
+ // Outside the project's folder: where the operator keeps hooks, which the chat's steps do not reach.
108
+ if (!rel || rel.startsWith('..') || isAbsolute(rel))
109
+ return null;
110
+ const path = slash(rel);
111
+ // In `.git`: the chat's steps may not write there (`repositoryInternalsRefusal`).
112
+ if (path === '.git' || path.startsWith('.git/'))
113
+ return null;
114
+ if (!(await git(top, ['--literal-pathspecs', 'ls-files', '--error-unmatch', '--', path])).ok)
115
+ return 'not-committed';
116
+ const diff = await git(top, ['--literal-pathspecs', 'diff', '--quiet', 'HEAD', '--', path]);
117
+ if (diff.code === 1 || !diff.ok)
118
+ return 'changed';
119
+ const last = await git(top, ['--literal-pathspecs', 'log', '-1', '--format=%ae', '--', path]);
120
+ if (last.stdout.trim().toLowerCase() === RUNNER_EMAIL)
121
+ return 'by-bot';
122
+ return null;
123
+ }
124
+ /**
125
+ * The hooks a commit or a push would run in this repository, and those of them that are not the project's own. The
126
+ * hooks folder is git's own answer, `core.hooksPath` included (read without the bot's own setting over it); with a
127
+ * hook in it, the other files there are taken in too, as a hook may read them (husky's `h`), and for a folder named
128
+ * `_` — husky's — the hook of the same name in the folder above, which husky's runs.
129
+ */
130
+ export async function hooksFor(dir, kind) {
131
+ const top = (await topOf(dir)) ?? dir;
132
+ const where = await git(top, ['rev-parse', '--path-format=absolute', '--git-path', 'hooks'], 30_000, undefined, { ownHooks: true });
133
+ const hooksDir = where.ok && where.stdout ? resolve(where.stdout) : null;
134
+ if (!hooksDir || !existsSync(hooksDir))
135
+ return { dir: hooksDir, run: [], flagged: [] };
136
+ const names = kind === 'commit' ? COMMIT_HOOKS : PUSH_HOOKS;
137
+ const hooks = names.map((n) => join(hooksDir, n)).filter(isFile);
138
+ if (hooks.length === 0)
139
+ return { dir: hooksDir, run: [], flagged: [] };
140
+ const files = new Set(hooks);
141
+ let entries = [];
142
+ try {
143
+ entries = readdirSync(hooksDir);
144
+ }
145
+ catch {
146
+ entries = [];
147
+ }
148
+ for (const e of entries) {
149
+ if (e.startsWith('.') || e.endsWith('.sample') || HOOK_NAMES.has(e))
150
+ continue;
151
+ if (isFile(join(hooksDir, e)))
152
+ files.add(join(hooksDir, e));
153
+ }
154
+ if (basename(hooksDir) === '_') {
155
+ for (const h of hooks) {
156
+ const above = join(dirname(hooksDir), basename(h));
157
+ if (isFile(above))
158
+ files.add(above);
159
+ }
160
+ }
161
+ const flagged = [];
162
+ for (const full of files) {
163
+ const why = await notOwn(top, full);
164
+ if (!why)
165
+ continue;
166
+ const rel = relative(top, full);
167
+ flagged.push({ path: rel && !rel.startsWith('..') && !isAbsolute(rel) ? slash(rel) : slash(full), why, sha: sha256(full) });
168
+ }
169
+ flagged.sort((a, b) => (a.path < b.path ? -1 : a.path > b.path ? 1 : 0));
170
+ return { dir: hooksDir, run: hooks.map((h) => slash(relative(top, h).startsWith('..') ? h : relative(top, h))), flagged };
171
+ }
172
+ /**
173
+ * The hooks as the operator chose: those flagged and neither remembered nor chosen now are what the operator is asked
174
+ * about. A choice to run them counts for a file only as it was shown (its hash then), and is remembered so.
175
+ */
176
+ async function decideHooks(top, kind, choice, trusted) {
177
+ if (choice.hooks === 'skip')
178
+ return { run: false, ask: [] };
179
+ const found = await hooksFor(top, kind);
180
+ if (found.run.length === 0)
181
+ return { run: false, ask: [] };
182
+ const ask = [];
183
+ const chosen = [];
184
+ for (const f of found.flagged) {
185
+ if (await trusted.has(top, f.path, f.sha))
186
+ continue;
187
+ if (choice.trust?.some((t) => t.path === f.path && t.sha === f.sha))
188
+ chosen.push(f);
189
+ else
190
+ ask.push(f);
191
+ }
192
+ if (ask.length > 0)
193
+ return { run: false, ask };
194
+ await trusted.add(top, chosen);
195
+ return { run: true, ask: [] };
196
+ }
197
+ /** The first lines of a message, as a command line shows it. */
198
+ function quoted(message) {
199
+ const first = message.trim().split(/\r?\n/)[0] ?? '';
200
+ const shown = first.length > 72 ? `${first.slice(0, 71)}…` : first;
201
+ return `"${shown.replace(/"/g, '\\"')}"${message.trim().includes('\n') ? ' …' : ''}`;
202
+ }
203
+ /** Why a commit did not go through, from what git and the hooks said. */
204
+ export function commitCause(output, hooksRan, timedOut) {
205
+ if (timedOut)
206
+ return 'timeout';
207
+ if (/please tell me who you are|author identity unknown|unable to auto-detect email address|empty ident name|committer identity unknown|no (name|email) was given and auto-detection is disabled/i.test(output))
208
+ return 'identity';
209
+ if (/nothing to commit|no changes added to commit|nothing added to commit/i.test(output))
210
+ return 'nothing';
211
+ if (/aborting commit due to empty commit message/i.test(output))
212
+ return 'message';
213
+ if (/unmerged files|resolve your current index first|fix conflicts and then commit|you have not concluded your merge/i.test(output))
214
+ return 'unmerged';
215
+ if (/index\.lock'?:? file exists|unable to create '.*\.lock'|another git process seems to be running/i.test(output))
216
+ return 'lock';
217
+ if (/gpg failed to sign|failed to sign the data|error: gpg|signing failed|ssh-keygen.*sign|couldn't load public key|error: load key/i.test(output))
218
+ return 'signing';
219
+ if (hooksRan)
220
+ return 'hook';
221
+ return 'unknown';
222
+ }
223
+ /** Why a push did not go through. */
224
+ export function pushCause(output, hooksRan, timedOut) {
225
+ if (timedOut)
226
+ return 'timeout';
227
+ if (/\[rejected\][^\n]*\((fetch first|non-fast-forward)\)|updates were rejected because the (remote contains work|tip of your current branch is behind)/i.test(output))
228
+ return 'behind';
229
+ if (/authentication failed|could not read (username|password)|permission denied \(publickey|access denied|terminal prompts disabled|invalid username or password|the requested url returned error: 40[13]|host key verification failed|repository not found/i.test(output))
230
+ return 'auth';
231
+ if (/\[remote rejected\]|pre-receive hook declined|protected branch|GH0\d\d|push declined|denied to|remote: error/i.test(output))
232
+ return 'refused';
233
+ if (/could not resolve host|unable to access|failed to connect|connection (timed out|refused|reset)|network is unreachable|could not read from remote repository|the remote end hung up/i.test(output))
234
+ return 'network';
235
+ if (hooksRan)
236
+ return 'hook';
237
+ return 'unknown';
238
+ }
239
+ /**
240
+ * The operator's commit: the staged changes — or, with `all`, every change and new file, staged first — under the
241
+ * operator's own git name, with the message as written. The project's hooks run as `decideHooks` says; when some of
242
+ * them are not the project's own, nothing is staged or committed and the operator is asked (`state: 'hooks'`).
243
+ */
244
+ export async function commitAsOperator(dir, req, trusted, update) {
245
+ const message = req.message.replace(/\r\n/g, '\n').trim();
246
+ const end = (patch) => update({ endedAt: new Date().toISOString(), ...patch });
247
+ if (!message)
248
+ return end({ state: 'failed', cause: 'message' });
249
+ const top = await topOf(dir);
250
+ if (!top)
251
+ return end({ state: 'failed', cause: 'unknown', output: `${dir} is not a git repository.\n` });
252
+ const branch = (await git(top, ['symbolic-ref', '--quiet', '--short', 'HEAD'])).stdout || undefined;
253
+ update({ ...(branch ? { branch } : {}) });
254
+ const head = (await git(top, ['rev-parse', '--verify', '--quiet', 'HEAD'])).ok;
255
+ const staged = await git(top, ['diff', '--cached', '--name-only', head ? 'HEAD' : '4b825dc642cb6eb9a060e54bf8d69288fbee4904']);
256
+ const anyStaged = staged.ok && staged.stdout.trim() !== '';
257
+ if (!anyStaged && !req.all)
258
+ return end({ state: 'failed', cause: 'nothing' });
259
+ if (!anyStaged) {
260
+ const changed = await git(top, ['status', '--porcelain', '--untracked-files=all']);
261
+ if (!changed.stdout.trim())
262
+ return end({ state: 'failed', cause: 'nothing' });
263
+ }
264
+ const hooks = await decideHooks(top, 'commit', req, trusted);
265
+ if (hooks.ask.length > 0)
266
+ return end({ state: 'hooks', flagged: hooks.ask, hooks: 'none' });
267
+ let output = '';
268
+ if (req.all) {
269
+ const added = await git(top, ['add', '-A', '--', '.'], 5 * MINUTES);
270
+ output = [added.stdout, added.stderr].filter(Boolean).join('\n');
271
+ if (!added.ok)
272
+ return end({ state: 'failed', cause: commitCause(output, false, false), output: `${output || 'git add failed'}\n` });
273
+ if (output)
274
+ output += '\n';
275
+ }
276
+ const command = `git ${req.all ? 'add -A && git ' : ''}commit -m ${quoted(message)}`;
277
+ update({ command, hooks: hooks.run ? 'run' : req.hooks === 'skip' ? 'skipped' : 'none', output });
278
+ const ran = await gitLive(top, ['commit', '-m', message], {
279
+ ownHooks: hooks.run,
280
+ timeoutMs: OP_TIMEOUT_MS,
281
+ env: { ...process.env, GIT_TERMINAL_PROMPT: '0' },
282
+ onOutput: (o, cut) => update({ output: output + o, ...(cut ? { cut } : {}) }),
283
+ });
284
+ const all = output + ran.output;
285
+ if (!ran.ok)
286
+ return end({ state: 'failed', cause: commitCause(all, hooks.run, ran.timedOut), output: all });
287
+ const made = (await git(top, ['rev-parse', 'HEAD'])).stdout;
288
+ end({ state: 'done', output: all, ...(made ? { commit: made } : {}) });
289
+ }
290
+ /**
291
+ * The operator's push of the branch the folder is on: to its upstream, or — a branch that has none — published on the
292
+ * remote (`origin`, else the only one) under its own name and followed from then on. With Git's own password window
293
+ * when the remote asks (`remoteAuth.ts`), which the bot never reads; the view says while it is open. Never forced.
294
+ */
295
+ export async function pushAsOperator(dir, req, trusted, update,
296
+ /** Git's password window; looked for next to git when not given. null: none, as a check that pops no window gives. */
297
+ askpassGiven) {
298
+ const end = (patch) => update({ endedAt: new Date().toISOString(), ...patch });
299
+ const top = await topOf(dir);
300
+ if (!top)
301
+ return end({ state: 'failed', cause: 'unknown', output: `${dir} is not a git repository.\n` });
302
+ const branch = (await git(top, ['symbolic-ref', '--quiet', '--short', 'HEAD'])).stdout;
303
+ if (!branch)
304
+ return end({ state: 'failed', cause: 'detached' });
305
+ update({ branch });
306
+ let remote = (await git(top, ['config', '--get', `branch.${branch}.remote`])).stdout.trim();
307
+ const merge = (await git(top, ['config', '--get', `branch.${branch}.merge`])).stdout.trim();
308
+ let target = merge.startsWith('refs/heads/') ? merge.slice('refs/heads/'.length) : '';
309
+ let publish = false;
310
+ if (!remote || remote === '.' || !target) {
311
+ const remotes = (await git(top, ['remote'])).stdout.split(/\r?\n/).map((r) => r.trim()).filter(Boolean);
312
+ remote = remotes.includes('origin') ? 'origin' : (remotes[0] ?? '');
313
+ if (!remote)
314
+ return end({ state: 'failed', cause: 'no-remote' });
315
+ target = branch;
316
+ publish = true;
317
+ }
318
+ update({ target: `${remote}/${target}`, published: publish });
319
+ const hooks = await decideHooks(top, 'push', req, trusted);
320
+ if (hooks.ask.length > 0)
321
+ return end({ state: 'hooks', flagged: hooks.ask, hooks: 'none' });
322
+ const askpass = askpassGiven === undefined ? await askpassProgram() : askpassGiven;
323
+ const env = askpass ? operatorFetchEnv(askpass) : { ...process.env, GIT_TERMINAL_PROMPT: '0', GCM_INTERACTIVE: 'auto' };
324
+ const args = ['push', ...(publish ? ['--set-upstream'] : []), remote, `HEAD:refs/heads/${target}`];
325
+ update({ command: `git ${args.join(' ')}`, hooks: hooks.run ? 'run' : req.hooks === 'skip' ? 'skipped' : 'none' });
326
+ const started = new Date(Date.now() - 1000);
327
+ let watching = !!askpass && process.platform === 'win32';
328
+ const watch = async () => {
329
+ while (watching) {
330
+ await new Promise((r) => setTimeout(r, 2_000));
331
+ if (!watching)
332
+ break;
333
+ const open = await passwordWindowOpen(started.getTime()).catch(() => false);
334
+ if (watching)
335
+ update({ passwordWindow: open });
336
+ }
337
+ };
338
+ void watch();
339
+ const ran = await gitLive(top, args, {
340
+ ownHooks: hooks.run,
341
+ timeoutMs: OP_TIMEOUT_MS,
342
+ env,
343
+ windowsHide: !askpass,
344
+ onOutput: (o, cut) => update({ output: o, ...(cut ? { cut } : {}) }),
345
+ });
346
+ watching = false;
347
+ if (ran.timedOut && askpass)
348
+ await closePasswordWindows(askpass, started).catch(() => 0);
349
+ if (!ran.ok)
350
+ return end({ state: 'failed', cause: pushCause(ran.output, hooks.run, ran.timedOut), output: ran.output, passwordWindow: false });
351
+ end({ state: 'done', output: ran.output, passwordWindow: false, upToDate: /everything up-to-date/i.test(ran.output) });
352
+ }
353
+ /**
354
+ * Files staged (`stage`) or taken back out of the index (`unstage`), as the Git view lists them: each named one must be
355
+ * one of the list it is in — a change for staging, a staged change for unstaging — so nothing else of the repository
356
+ * is reached; `all` takes the whole list. Nothing in the working tree is changed either way.
357
+ */
358
+ export async function stageFiles(dir, how, which) {
359
+ const top = await topOf(dir);
360
+ if (!top)
361
+ throw new Error('The project folder is not a git repository.');
362
+ const state = await workspaceGit(dir);
363
+ const list = how === 'stage' ? state.changes : state.staged;
364
+ // The untracked ones are named from the folder, the rest from the repository's top: all from the top here.
365
+ const fromTop = (f) => (f.status === 'U' ? slash(relative(top, resolve(dir, f.path))) : f.path);
366
+ const chosen = which === 'all' ? list : list.filter((f) => which.includes(f.path));
367
+ if (which !== 'all') {
368
+ const unknown = which.filter((p) => !list.some((f) => f.path === p));
369
+ if (unknown.length > 0)
370
+ throw new Error(`${how === 'stage' ? 'Not a change of the folder' : 'Not a staged change'}: ${unknown.slice(0, 3).join(', ')}. Read the folder again.`);
371
+ }
372
+ const paths = [...new Set(chosen.flatMap((f) => [fromTop(f), ...(f.oldPath ? [f.oldPath] : [])]))];
373
+ if (paths.length === 0)
374
+ return;
375
+ const head = (await git(top, ['rev-parse', '--verify', '--quiet', 'HEAD'])).ok;
376
+ for (let i = 0; i < paths.length; i += 100) {
377
+ const some = paths.slice(i, i + 100);
378
+ const args = how === 'stage'
379
+ ? ['--literal-pathspecs', 'add', '-A', '--', ...some]
380
+ : head
381
+ ? ['--literal-pathspecs', 'restore', '--staged', '--', ...some]
382
+ : ['--literal-pathspecs', 'rm', '--cached', '-r', '-q', '--', ...some];
383
+ const r = await git(top, args, 5 * MINUTES);
384
+ if (!r.ok)
385
+ throw new Error(`git ${args[1]} did not go through: ${(r.stderr || r.stdout).split(/\r?\n/).slice(0, 3).join(' ')}`);
386
+ }
387
+ }
388
+ /** The operator's name and e-mail for git, in this repository or for all of theirs (`global`): what a first commit asks for. */
389
+ export async function setIdentity(dir, input) {
390
+ const top = await topOf(dir);
391
+ if (!top)
392
+ throw new Error('The project folder is not a git repository.');
393
+ const name = input.name.trim();
394
+ const email = input.email.trim();
395
+ if (!name || name.length > 200 || /[\r\n<>]/.test(name))
396
+ throw new Error('Write your name as git should put it on a commit.');
397
+ if (!/^[^\s@<>]+@[^\s@<>]+$/.test(email) || email.length > 200)
398
+ throw new Error('Write an e-mail address, as name@example.com.');
399
+ for (const [key, value] of [['user.name', name], ['user.email', email]]) {
400
+ const r = await git(top, ['config', ...(input.global ? ['--global'] : ['--local']), key, value]);
401
+ if (!r.ok)
402
+ throw new Error(`git config ${key} did not go through: ${r.stderr || r.stdout}`);
403
+ }
404
+ }
405
+ /** The operator's name and e-mail as git has them for this repository, and where from; empty when git has none. */
406
+ export async function identityOf(dir) {
407
+ const top = (await topOf(dir)) ?? dir;
408
+ return { name: (await git(top, ['config', 'user.name'])).stdout.trim(), email: (await git(top, ['config', 'user.email'])).stdout.trim() };
409
+ }
package/dist/web/404.html CHANGED
@@ -1,4 +1,4 @@
1
- <!DOCTYPE html><!--WU_J4Ke1d3xVfpW2acqqf--><html lang="en" data-theme="light" data-textsize="normal" data-contrast="normal" data-motion="normal" data-links="plain" data-focus="normal" data-night="off"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/css/f152f27d6afce55c.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/webpack-19a2d7161f23b21d.js"/><script src="/_next/static/chunks/c7879cf7-fabe25011515220e.js" async=""></script><script src="/_next/static/chunks/3131-8ec8b632ebf0450d.js" async=""></script><script src="/_next/static/chunks/main-app-d23441ca81b3a063.js" async=""></script><script src="/_next/static/chunks/8197-e2fcb43f38a2b4a7.js" async=""></script><script src="/_next/static/chunks/7921-3d21f385338afdf9.js" async=""></script><script src="/_next/static/chunks/895-a178f989a2e5d489.js" async=""></script><script src="/_next/static/chunks/8124-1dc34be1646970a8.js" async=""></script><script src="/_next/static/chunks/app/layout-b8a1e0075a48b025.js" async=""></script><meta name="robots" content="noindex"/><title>404: This page could not be found.</title><title>copilot-operator</title><meta name="description" content="Runs task loops with Microsoft 365 Copilot on this machine."/><link rel="icon" href="/icon.svg?23b6e9b8199c9069" type="image/svg+xml" sizes="any"/><script>(function(){try{
1
+ <!DOCTYPE html><!--aCQe1FDhYTj4zGeI5ueVq--><html lang="en" data-theme="light" data-textsize="normal" data-contrast="normal" data-motion="normal" data-links="plain" data-focus="normal" data-night="off"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/css/6e2b8656501f0dd7.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/webpack-13ccb80d7b7094ca.js"/><script src="/_next/static/chunks/c7879cf7-fabe25011515220e.js" async=""></script><script src="/_next/static/chunks/3131-8ec8b632ebf0450d.js" async=""></script><script src="/_next/static/chunks/main-app-d23441ca81b3a063.js" async=""></script><script src="/_next/static/chunks/8197-e2fcb43f38a2b4a7.js" async=""></script><script src="/_next/static/chunks/7921-65dd56d87144bd44.js" async=""></script><script src="/_next/static/chunks/895-a178f989a2e5d489.js" async=""></script><script src="/_next/static/chunks/8124-1dba8babfcfbc6e2.js" async=""></script><script src="/_next/static/chunks/app/layout-127e5af1ebf21876.js" async=""></script><meta name="robots" content="noindex"/><title>404: This page could not be found.</title><title>copilot-operator</title><meta name="description" content="Runs task loops with Microsoft 365 Copilot on this machine."/><link rel="icon" href="/icon.svg?23b6e9b8199c9069" type="image/svg+xml" sizes="any"/><script>(function(){try{
2
2
  var d=document.documentElement,raw=localStorage.getItem('cop.appearance'),a=raw?JSON.parse(raw):{};
3
3
  if(!a||typeof a!=='object')a={};
4
4
  d.dataset.theme=a.theme==='dark'||a.theme==='light'?a.theme:window.matchMedia&&window.matchMedia('(prefers-color-scheme: dark)').matches?'dark':'light';
@@ -11,4 +11,4 @@ d.dataset.night=a.nightLight?'on':'off';
11
11
  d.dataset.cursor=a.systemCursor?'system':'own';
12
12
  var l=(localStorage.getItem('cop.locale')||'').toLowerCase();
13
13
  if(["ar"].indexOf(l)>=0){d.dir='rtl';d.lang=l;}
14
- }catch(e){}})();</script><script src="/_next/static/chunks/polyfills-42372ed130431b0a.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><a class="skip-link" href="#main">Skip to the content</a><div class="wrap"><header class="top"><h1><a class="brand-link" href="/"><svg class="brand-logo" viewBox="0 0 200 120" aria-hidden="true" focusable="false"><defs><mask id="cop-logo-R56db" maskUnits="userSpaceOnUse" x="0" y="0" width="200" height="120"><rect width="200" height="120" fill="#fff"></rect><path d="M50 3L94 60L94 62.6L69.5 89.6L30.5 89.6L6 62.6L6 60Z" transform="translate(104 14) scale(0.74) rotate(42 50 50)" fill="#000" stroke="#000" stroke-width="18" stroke-linejoin="round"></path></mask></defs><g mask="url(#cop-logo-R56db)" fill="none" stroke="var(--logo-orbit)" stroke-linecap="round"><ellipse cx="96" cy="64" rx="86" ry="36" transform="rotate(-25 96 64)" stroke-width="6.5"></ellipse><path d="M70 104 C112 124 166 112 186 86 C194 74 192 60 184 52" stroke-width="6"></path><path d="M22 28 C18 42 22 56 34 70" stroke-width="2.4"></path></g><path class="brand-plane" d="M50 3C54.6 3 56.6 8.2 56.6 14.5L56.6 35.5L91.5 55.8C93.2 56.8 94 58.2 94 60L94 62.6L56.6 52.8L55.4 74.5L69.5 84.6L69.5 89.6L52.6 85.6L50 89.8L47.4 85.6L30.5 89.6L30.5 84.6L44.6 74.5L43.4 52.8L6 62.6L6 60C6 58.2 6.8 56.8 8.5 55.8L43.4 35.5L43.4 14.5C43.4 8.2 45.4 3 50 3Z" transform="translate(104 14) scale(0.74) rotate(42 50 50)" fill="var(--logo-plane)"></path></svg>copilot-operator</a></h1><nav aria-label="Main"><a href="/"><svg class="nav-icon" viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true"><path d="M4 5h16v11H9l-5 4zM8 9h8M8 12h5" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round"></path></svg><span>Chat</span></a><a href="/queue"><svg class="nav-icon" viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true"><path d="M4 6h16M4 12h16M4 18h10M17 16l3 2-3 2z" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round" stroke-linecap="round"></path></svg><span>Queue</span></a><a href="/settings"><svg class="nav-icon" viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true"><path d="M12 8a4 4 0 1 0 0 8 4 4 0 0 0 0-8zm8.5 4 1.5 1-1.6 2.8-1.8-.4a7 7 0 0 1-1.5 1.5l.4 1.8L14.7 21l-1-1.5a7 7 0 0 1-3.4 0l-1 1.5-2.8-1.6.4-1.8A7 7 0 0 1 5.4 16l-1.8.4L2 13.6 3.5 12.6V11.4L2 10.4l1.6-2.8 1.8.4A7 7 0 0 1 6.9 6.5l-.4-1.8L9.3 3l1 1.5a7 7 0 0 1 3.4 0l1-1.5 2.8 1.6-.4 1.8a7 7 0 0 1 1.5 1.5l1.8-.4L22 10.4l-1.5 1z"></path></svg><span>Settings</span></a><a href="/system"><svg class="nav-icon" viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true"><path d="M4 5h16v10H4zM2 19h20M9 15v4M15 15v4" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round"></path></svg><span>System</span></a><span class="nav-pair"><button type="button" class="lang-btn ap-btn" aria-label="Appearance: theme and text" title="Appearance: theme and text" aria-expanded="false"><svg viewBox="0 0 24 24" width="16" height="16" fill="none" stroke="currentColor" stroke-width="1.8" aria-hidden="true"><circle cx="12" cy="12" r="8.5"></circle><path d="M12 3.5a8.5 8.5 0 0 1 0 17z" fill="currentColor" stroke="none"></path></svg><span aria-hidden="true">Appearance</span></button><span class="lang-menu"><button type="button" class="lang-btn" aria-haspopup="menu" aria-expanded="false" title="The language of the interface"><svg class="lang-globe" viewBox="0 0 16 16" aria-hidden="true"><circle cx="8" cy="8" r="6.5" fill="none" stroke="currentColor" stroke-width="1.3"></circle><path d="M1.5 8h13M8 1.5c2 2 2.8 4 2.8 6.5S10 12.5 8 14.5M8 1.5C6 3.5 5.2 5.5 5.2 8S6 12.5 8 14.5" fill="none" stroke="currentColor" stroke-width="1.1"></path></svg><span lang="en">Language</span><span aria-hidden="true">▾</span></button></span></span></nav></header><main id="main"><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--></main></div><script src="/_next/static/chunks/webpack-19a2d7161f23b21d.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[98078,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-3d21f385338afdf9.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dc34be1646970a8.js\",\"7177\",\"static/chunks/app/layout-b8a1e0075a48b025.js\"],\"AppearanceProvider\"]\n3:I[8205,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-3d21f385338afdf9.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dc34be1646970a8.js\",\"7177\",\"static/chunks/app/layout-b8a1e0075a48b025.js\"],\"LanguageProvider\"]\n4:I[51035,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-3d21f385338afdf9.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dc34be1646970a8.js\",\"7177\",\"static/chunks/app/layout-b8a1e0075a48b025.js\"],\"DialogHost\"]\n5:I[16752,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-3d21f385338afdf9.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dc34be1646970a8.js\",\"7177\",\"static/chunks/app/layout-b8a1e0075a48b025.js\"],\"SkipLink\"]\n6:I[19050,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-3d21f385338afdf9.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dc34be1646970a8.js\",\"7177\",\"static/chunks/app/layout-b8a1e0075a48b025.js\"],\"Shell\"]\n7:I[25204,[],\"\"]\n8:I[42642,[],\"\"]\n9:I[87712,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-3d21f385338afdf9.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dc34be1646970a8.js\",\"7177\",\"static/chunks/app/layout-b8a1e0075a48b025.js\"],\"ScrollJump\"]\na:I[60433,[],\"OutletBoundary\"]\nc:I[19884,[],\"AsyncMetadataOutlet\"]\ne:I[60433,[],\"ViewportBoundary\"]\n10:I[60433,[],\"MetadataBoundary\"]\n11:\"$Sreact.suspense\"\n13:I[3536,[],\"\"]\n:HL[\"/_next/static/css/f152f27d6afce55c.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"b\":\"WU_J4Ke1d3xVfpW2acqqf\",\"p\":\"\",\"c\":[\"\",\"_not-found\"],\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],[\"\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/f152f27d6afce55c.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"suppressHydrationWarning\":true,\"data-theme\":\"light\",\"data-textsize\":\"normal\",\"data-contrast\":\"normal\",\"data-motion\":\"normal\",\"data-links\":\"plain\",\"data-focus\":\"normal\",\"data-night\":\"off\",\"children\":[[\"$\",\"head\",null,{\"children\":[\"$\",\"script\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"(function(){try{\\nvar d=document.documentElement,raw=localStorage.getItem('cop.appearance'),a=raw?JSON.parse(raw):{};\\nif(!a||typeof a!=='object')a={};\\nd.dataset.theme=a.theme==='dark'||a.theme==='light'?a.theme:window.matchMedia\u0026\u0026window.matchMedia('(prefers-color-scheme: dark)').matches?'dark':'light';\\nd.dataset.textsize=[\\\"smallest\\\",\\\"verysmall\\\",\\\"compact\\\",\\\"small\\\",\\\"normal\\\",\\\"large\\\",\\\"huge\\\",\\\"giant\\\"].indexOf(a.textSize)\u003e=0?a.textSize:'normal';\\nd.dataset.contrast=a.highContrast?'high':'normal';\\nd.dataset.motion=a.reduceMotion?'reduced':'normal';\\nd.dataset.links=a.underlineLinks?'underline':'plain';\\nd.dataset.focus=a.strongFocus?'strong':'normal';\\nd.dataset.night=a.nightLight?'on':'off';\\nd.dataset.cursor=a.systemCursor?'system':'own';\\nvar l=(localStorage.getItem('cop.locale')||'').toLowerCase();\\nif([\\\"ar\\\"].indexOf(l)\u003e=0){d.dir='rtl';d.lang=l;}\\n}catch(e){}})();\"}}]}],[\"$\",\"body\",null,{\"children\":[\"$\",\"$L2\",null,{\"children\":[\"$\",\"$L3\",null,{\"children\":[\"$\",\"$L4\",null,{\"children\":[[\"$\",\"$L5\",null,{}],[\"$\",\"$L6\",null,{\"children\":[\"$\",\"$L7\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L8\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}],[\"$\",\"$L9\",null,{}]]}]}]}]}]]}]]}],{\"children\":[\"/_not-found\",[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L7\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L8\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[\"__PAGE__\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$La\",null,{\"children\":[\"$Lb\",[\"$\",\"$Lc\",null,{\"promise\":\"$@d\"}]]}]]}],{},null,false]},null,false]},null,false],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[[\"$\",\"$Le\",null,{\"children\":\"$Lf\"}],null],[\"$\",\"$L10\",null,{\"children\":[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$11\",null,{\"fallback\":null,\"children\":\"$L12\"}]}]}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$13\",[]],\"s\":false,\"S\":true}\n"])</script><script>self.__next_f.push([1,"f:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\nb:null\n"])</script><script>self.__next_f.push([1,"14:I[66644,[],\"IconMark\"]\nd:{\"metadata\":[[\"$\",\"title\",\"0\",{\"children\":\"copilot-operator\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Runs task loops with Microsoft 365 Copilot on this machine.\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/icon.svg?23b6e9b8199c9069\",\"type\":\"image/svg+xml\",\"sizes\":\"any\"}],[\"$\",\"$L14\",\"3\",{}]],\"error\":null,\"digest\":\"$undefined\"}\n"])</script><script>self.__next_f.push([1,"12:\"$d:metadata\"\n"])</script></body></html>
14
+ }catch(e){}})();</script><script src="/_next/static/chunks/polyfills-42372ed130431b0a.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><a class="skip-link" href="#main">Skip to the content</a><div class="wrap"><header class="top"><h1><a class="brand-link" href="/"><svg class="brand-logo" viewBox="0 0 200 120" aria-hidden="true" focusable="false"><defs><mask id="cop-logo-R56db" maskUnits="userSpaceOnUse" x="0" y="0" width="200" height="120"><rect width="200" height="120" fill="#fff"></rect><path d="M50 3L94 60L94 62.6L69.5 89.6L30.5 89.6L6 62.6L6 60Z" transform="translate(104 14) scale(0.74) rotate(42 50 50)" fill="#000" stroke="#000" stroke-width="18" stroke-linejoin="round"></path></mask></defs><g mask="url(#cop-logo-R56db)" fill="none" stroke="var(--logo-orbit)" stroke-linecap="round"><ellipse cx="96" cy="64" rx="86" ry="36" transform="rotate(-25 96 64)" stroke-width="6.5"></ellipse><path d="M70 104 C112 124 166 112 186 86 C194 74 192 60 184 52" stroke-width="6"></path><path d="M22 28 C18 42 22 56 34 70" stroke-width="2.4"></path></g><path class="brand-plane" d="M50 3C54.6 3 56.6 8.2 56.6 14.5L56.6 35.5L91.5 55.8C93.2 56.8 94 58.2 94 60L94 62.6L56.6 52.8L55.4 74.5L69.5 84.6L69.5 89.6L52.6 85.6L50 89.8L47.4 85.6L30.5 89.6L30.5 84.6L44.6 74.5L43.4 52.8L6 62.6L6 60C6 58.2 6.8 56.8 8.5 55.8L43.4 35.5L43.4 14.5C43.4 8.2 45.4 3 50 3Z" transform="translate(104 14) scale(0.74) rotate(42 50 50)" fill="var(--logo-plane)"></path></svg>copilot-operator</a></h1><nav aria-label="Main"><a href="/"><svg class="nav-icon" viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true"><path d="M4 5h16v11H9l-5 4zM8 9h8M8 12h5" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round"></path></svg><span>Chat</span></a><a href="/queue"><svg class="nav-icon" viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true"><path d="M4 6h16M4 12h16M4 18h10M17 16l3 2-3 2z" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round" stroke-linecap="round"></path></svg><span>Queue</span></a><a href="/settings"><svg class="nav-icon" viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true"><path d="M12 8a4 4 0 1 0 0 8 4 4 0 0 0 0-8zm8.5 4 1.5 1-1.6 2.8-1.8-.4a7 7 0 0 1-1.5 1.5l.4 1.8L14.7 21l-1-1.5a7 7 0 0 1-3.4 0l-1 1.5-2.8-1.6.4-1.8A7 7 0 0 1 5.4 16l-1.8.4L2 13.6 3.5 12.6V11.4L2 10.4l1.6-2.8 1.8.4A7 7 0 0 1 6.9 6.5l-.4-1.8L9.3 3l1 1.5a7 7 0 0 1 3.4 0l1-1.5 2.8 1.6-.4 1.8a7 7 0 0 1 1.5 1.5l1.8-.4L22 10.4l-1.5 1z"></path></svg><span>Settings</span></a><a href="/system"><svg class="nav-icon" viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true"><path d="M4 5h16v10H4zM2 19h20M9 15v4M15 15v4" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round"></path></svg><span>System</span></a><span class="nav-pair"><button type="button" class="lang-btn ap-btn" aria-label="Appearance: theme and text" title="Appearance: theme and text" aria-expanded="false"><svg viewBox="0 0 24 24" width="16" height="16" fill="none" stroke="currentColor" stroke-width="1.8" aria-hidden="true"><circle cx="12" cy="12" r="8.5"></circle><path d="M12 3.5a8.5 8.5 0 0 1 0 17z" fill="currentColor" stroke="none"></path></svg><span aria-hidden="true">Appearance</span></button><span class="lang-menu"><button type="button" class="lang-btn" aria-haspopup="menu" aria-expanded="false" title="The language of the interface"><svg class="lang-globe" viewBox="0 0 16 16" aria-hidden="true"><circle cx="8" cy="8" r="6.5" fill="none" stroke="currentColor" stroke-width="1.3"></circle><path d="M1.5 8h13M8 1.5c2 2 2.8 4 2.8 6.5S10 12.5 8 14.5M8 1.5C6 3.5 5.2 5.5 5.2 8S6 12.5 8 14.5" fill="none" stroke="currentColor" stroke-width="1.1"></path></svg><span lang="en">Language</span><span aria-hidden="true">▾</span></button></span></span></nav></header><main id="main"><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--></main></div><script src="/_next/static/chunks/webpack-13ccb80d7b7094ca.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[98078,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-65dd56d87144bd44.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dba8babfcfbc6e2.js\",\"7177\",\"static/chunks/app/layout-127e5af1ebf21876.js\"],\"AppearanceProvider\"]\n3:I[8205,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-65dd56d87144bd44.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dba8babfcfbc6e2.js\",\"7177\",\"static/chunks/app/layout-127e5af1ebf21876.js\"],\"LanguageProvider\"]\n4:I[51035,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-65dd56d87144bd44.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dba8babfcfbc6e2.js\",\"7177\",\"static/chunks/app/layout-127e5af1ebf21876.js\"],\"DialogHost\"]\n5:I[16752,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-65dd56d87144bd44.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dba8babfcfbc6e2.js\",\"7177\",\"static/chunks/app/layout-127e5af1ebf21876.js\"],\"SkipLink\"]\n6:I[19050,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-65dd56d87144bd44.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dba8babfcfbc6e2.js\",\"7177\",\"static/chunks/app/layout-127e5af1ebf21876.js\"],\"Shell\"]\n7:I[25204,[],\"\"]\n8:I[42642,[],\"\"]\n9:I[87712,[\"8197\",\"static/chunks/8197-e2fcb43f38a2b4a7.js\",\"7921\",\"static/chunks/7921-65dd56d87144bd44.js\",\"895\",\"static/chunks/895-a178f989a2e5d489.js\",\"8124\",\"static/chunks/8124-1dba8babfcfbc6e2.js\",\"7177\",\"static/chunks/app/layout-127e5af1ebf21876.js\"],\"ScrollJump\"]\na:I[60433,[],\"OutletBoundary\"]\nc:I[19884,[],\"AsyncMetadataOutlet\"]\ne:I[60433,[],\"ViewportBoundary\"]\n10:I[60433,[],\"MetadataBoundary\"]\n11:\"$Sreact.suspense\"\n13:I[3536,[],\"\"]\n:HL[\"/_next/static/css/6e2b8656501f0dd7.css\",\"style\"]\n"])</script><script>self.__next_f.push([1,"0:{\"P\":null,\"b\":\"aCQe1FDhYTj4zGeI5ueVq\",\"p\":\"\",\"c\":[\"\",\"_not-found\"],\"i\":false,\"f\":[[[\"\",{\"children\":[\"/_not-found\",{\"children\":[\"__PAGE__\",{}]}]},\"$undefined\",\"$undefined\",true],[\"\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/6e2b8656501f0dd7.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"suppressHydrationWarning\":true,\"data-theme\":\"light\",\"data-textsize\":\"normal\",\"data-contrast\":\"normal\",\"data-motion\":\"normal\",\"data-links\":\"plain\",\"data-focus\":\"normal\",\"data-night\":\"off\",\"children\":[[\"$\",\"head\",null,{\"children\":[\"$\",\"script\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"(function(){try{\\nvar d=document.documentElement,raw=localStorage.getItem('cop.appearance'),a=raw?JSON.parse(raw):{};\\nif(!a||typeof a!=='object')a={};\\nd.dataset.theme=a.theme==='dark'||a.theme==='light'?a.theme:window.matchMedia\u0026\u0026window.matchMedia('(prefers-color-scheme: dark)').matches?'dark':'light';\\nd.dataset.textsize=[\\\"smallest\\\",\\\"verysmall\\\",\\\"compact\\\",\\\"small\\\",\\\"normal\\\",\\\"large\\\",\\\"huge\\\",\\\"giant\\\"].indexOf(a.textSize)\u003e=0?a.textSize:'normal';\\nd.dataset.contrast=a.highContrast?'high':'normal';\\nd.dataset.motion=a.reduceMotion?'reduced':'normal';\\nd.dataset.links=a.underlineLinks?'underline':'plain';\\nd.dataset.focus=a.strongFocus?'strong':'normal';\\nd.dataset.night=a.nightLight?'on':'off';\\nd.dataset.cursor=a.systemCursor?'system':'own';\\nvar l=(localStorage.getItem('cop.locale')||'').toLowerCase();\\nif([\\\"ar\\\"].indexOf(l)\u003e=0){d.dir='rtl';d.lang=l;}\\n}catch(e){}})();\"}}]}],[\"$\",\"body\",null,{\"children\":[\"$\",\"$L2\",null,{\"children\":[\"$\",\"$L3\",null,{\"children\":[\"$\",\"$L4\",null,{\"children\":[[\"$\",\"$L5\",null,{}],[\"$\",\"$L6\",null,{\"children\":[\"$\",\"$L7\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L8\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}],[\"$\",\"$L9\",null,{}]]}]}]}]}]]}]]}],{\"children\":[\"/_not-found\",[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L7\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L8\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[\"__PAGE__\",[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$La\",null,{\"children\":[\"$Lb\",[\"$\",\"$Lc\",null,{\"promise\":\"$@d\"}]]}]]}],{},null,false]},null,false]},null,false],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[[\"$\",\"$Le\",null,{\"children\":\"$Lf\"}],null],[\"$\",\"$L10\",null,{\"children\":[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$11\",null,{\"fallback\":null,\"children\":\"$L12\"}]}]}]]}],false]],\"m\":\"$undefined\",\"G\":[\"$13\",[]],\"s\":false,\"S\":true}\n"])</script><script>self.__next_f.push([1,"f:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\nb:null\n"])</script><script>self.__next_f.push([1,"14:I[66644,[],\"IconMark\"]\nd:{\"metadata\":[[\"$\",\"title\",\"0\",{\"children\":\"copilot-operator\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Runs task loops with Microsoft 365 Copilot on this machine.\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/icon.svg?23b6e9b8199c9069\",\"type\":\"image/svg+xml\",\"sizes\":\"any\"}],[\"$\",\"$L14\",\"3\",{}]],\"error\":null,\"digest\":\"$undefined\"}\n"])</script><script>self.__next_f.push([1,"12:\"$d:metadata\"\n"])</script></body></html>