@oisincoveney/pipeline 1.27.8 → 1.27.10
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/config.d.ts
CHANGED
|
@@ -452,6 +452,7 @@ declare const configSchema: z.ZodObject<{
|
|
|
452
452
|
skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
453
453
|
timeout_ms: z.ZodOptional<z.ZodNumber>;
|
|
454
454
|
tools: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
455
|
+
task: "task";
|
|
455
456
|
read: "read";
|
|
456
457
|
list: "list";
|
|
457
458
|
grep: "grep";
|
|
@@ -459,7 +460,6 @@ declare const configSchema: z.ZodObject<{
|
|
|
459
460
|
bash: "bash";
|
|
460
461
|
edit: "edit";
|
|
461
462
|
write: "write";
|
|
462
|
-
task: "task";
|
|
463
463
|
}>>>;
|
|
464
464
|
}, z.core.$strict>>>;
|
|
465
465
|
runner_command: z.ZodDefault<z.ZodObject<{
|
|
@@ -485,8 +485,8 @@ declare const configSchema: z.ZodObject<{
|
|
|
485
485
|
rules: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
486
486
|
path: z.ZodString;
|
|
487
487
|
source_root: z.ZodDefault<z.ZodEnum<{
|
|
488
|
-
package: "package";
|
|
489
488
|
project: "project";
|
|
489
|
+
package: "package";
|
|
490
490
|
}>>;
|
|
491
491
|
}, z.core.$strict>>>;
|
|
492
492
|
runners: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
@@ -511,6 +511,7 @@ declare const configSchema: z.ZodObject<{
|
|
|
511
511
|
rules: z.ZodOptional<z.ZodBoolean>;
|
|
512
512
|
skills: z.ZodOptional<z.ZodBoolean>;
|
|
513
513
|
tools: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
514
|
+
task: "task";
|
|
514
515
|
read: "read";
|
|
515
516
|
list: "list";
|
|
516
517
|
grep: "grep";
|
|
@@ -518,7 +519,6 @@ declare const configSchema: z.ZodObject<{
|
|
|
518
519
|
bash: "bash";
|
|
519
520
|
edit: "edit";
|
|
520
521
|
write: "write";
|
|
521
|
-
task: "task";
|
|
522
522
|
}>>>;
|
|
523
523
|
}, z.core.$strict>;
|
|
524
524
|
command: z.ZodOptional<z.ZodString>;
|
|
@@ -613,8 +613,8 @@ declare const configSchema: z.ZodObject<{
|
|
|
613
613
|
schedules: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
614
614
|
description: z.ZodOptional<z.ZodString>;
|
|
615
615
|
baseline: z.ZodEnum<{
|
|
616
|
-
execute: "execute";
|
|
617
616
|
quick: "quick";
|
|
617
|
+
execute: "execute";
|
|
618
618
|
}>;
|
|
619
619
|
max_parallel_nodes: z.ZodOptional<z.ZodNumber>;
|
|
620
620
|
node_catalog: z.ZodOptional<z.ZodString>;
|
|
@@ -626,8 +626,8 @@ declare const configSchema: z.ZodObject<{
|
|
|
626
626
|
skills: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
627
627
|
path: z.ZodString;
|
|
628
628
|
source_root: z.ZodDefault<z.ZodEnum<{
|
|
629
|
-
package: "package";
|
|
630
629
|
project: "project";
|
|
630
|
+
package: "package";
|
|
631
631
|
}>>;
|
|
632
632
|
}, z.core.$strict>>>;
|
|
633
633
|
task_context: z.ZodOptional<z.ZodObject<{
|
package/dist/config.js
CHANGED
|
@@ -329,6 +329,11 @@ hooks:
|
|
|
329
329
|
- id: generated-defaults-audit
|
|
330
330
|
function: generated-defaults-audit
|
|
331
331
|
failure: fail
|
|
332
|
+
runner_command:
|
|
333
|
+
environment:
|
|
334
|
+
setup:
|
|
335
|
+
- command: pnpm
|
|
336
|
+
args: [install, --frozen-lockfile]
|
|
332
337
|
scheduler:
|
|
333
338
|
commands:
|
|
334
339
|
quick:
|
package/dist/moka-submit.d.ts
CHANGED
|
@@ -160,8 +160,8 @@ declare const mokaSubmitOptionsSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
160
160
|
}, z.core.$strict>>;
|
|
161
161
|
serviceAccountName: z.ZodDefault<z.ZodString>;
|
|
162
162
|
mode: z.ZodEnum<{
|
|
163
|
-
quick: "quick";
|
|
164
163
|
full: "full";
|
|
164
|
+
quick: "quick";
|
|
165
165
|
}>;
|
|
166
166
|
schedulePath: z.ZodOptional<z.ZodString>;
|
|
167
167
|
scheduleYaml: z.ZodOptional<z.ZodString>;
|
|
@@ -1,10 +1,14 @@
|
|
|
1
|
-
import { mkdirSync } from "node:fs";
|
|
1
|
+
import { chmodSync, copyFileSync, existsSync, mkdirSync } from "node:fs";
|
|
2
2
|
import { dirname, resolve } from "node:path";
|
|
3
|
+
import { tmpdir } from "node:os";
|
|
3
4
|
import { execFile } from "node:child_process";
|
|
4
5
|
import { promisify } from "node:util";
|
|
5
6
|
//#region src/run-state/git-refs.ts
|
|
6
7
|
const DEFAULT_WORKSPACE_PATH = "/workspace";
|
|
8
|
+
const DEFAULT_GIT_CREDENTIAL_STORE = "/root/.git-credentials";
|
|
9
|
+
const WRITABLE_GIT_CREDENTIAL_STORE = resolve(tmpdir(), "pipeline-git-credentials");
|
|
7
10
|
const execGit = promisify(execFile);
|
|
11
|
+
let preparedCredentialStore;
|
|
8
12
|
function runnerGitRefs(payload, nodeId) {
|
|
9
13
|
const prefix = `refs/heads/pipeline/runs/${payload.run.id}/${payload.workflow.id}`;
|
|
10
14
|
return {
|
|
@@ -97,12 +101,50 @@ async function configureGitCommitter(worktreePath, committer) {
|
|
|
97
101
|
committer.email
|
|
98
102
|
]);
|
|
99
103
|
}
|
|
104
|
+
function runnerGitCommandArgs(args) {
|
|
105
|
+
return [...gitCredentialConfigArgs(), ...args];
|
|
106
|
+
}
|
|
100
107
|
async function runGit(cwd, args) {
|
|
101
|
-
const { stdout } = await execGit("git", args, {
|
|
108
|
+
const { stdout } = await execGit("git", runnerGitCommandArgs(args), {
|
|
102
109
|
cwd,
|
|
103
|
-
encoding: "utf8"
|
|
110
|
+
encoding: "utf8",
|
|
111
|
+
env: {
|
|
112
|
+
...process.env,
|
|
113
|
+
GIT_TERMINAL_PROMPT: "0"
|
|
114
|
+
}
|
|
104
115
|
});
|
|
105
116
|
return stdout;
|
|
106
117
|
}
|
|
118
|
+
function gitCredentialConfigArgs() {
|
|
119
|
+
const writablePath = prepareWritableGitCredentialStore();
|
|
120
|
+
if (!writablePath) return [];
|
|
121
|
+
return [
|
|
122
|
+
"-c",
|
|
123
|
+
"credential.helper=",
|
|
124
|
+
"-c",
|
|
125
|
+
`credential.helper=store --file=${writablePath}`
|
|
126
|
+
];
|
|
127
|
+
}
|
|
128
|
+
function prepareWritableGitCredentialStore() {
|
|
129
|
+
const sourcePath = availableGitCredentialStore();
|
|
130
|
+
if (!sourcePath) return;
|
|
131
|
+
const writablePath = writableGitCredentialStore();
|
|
132
|
+
copyGitCredentialStore(sourcePath, writablePath);
|
|
133
|
+
return writablePath;
|
|
134
|
+
}
|
|
135
|
+
function availableGitCredentialStore() {
|
|
136
|
+
const sourcePath = process.env.PIPELINE_GIT_CREDENTIAL_STORE ?? DEFAULT_GIT_CREDENTIAL_STORE;
|
|
137
|
+
return existsSync(sourcePath) ? sourcePath : void 0;
|
|
138
|
+
}
|
|
139
|
+
function writableGitCredentialStore() {
|
|
140
|
+
return process.env.PIPELINE_WRITABLE_GIT_CREDENTIAL_STORE ?? WRITABLE_GIT_CREDENTIAL_STORE;
|
|
141
|
+
}
|
|
142
|
+
function copyGitCredentialStore(sourcePath, writablePath) {
|
|
143
|
+
if (preparedCredentialStore === writablePath) return;
|
|
144
|
+
mkdirSync(dirname(writablePath), { recursive: true });
|
|
145
|
+
copyFileSync(sourcePath, writablePath);
|
|
146
|
+
chmodSync(writablePath, 384);
|
|
147
|
+
preparedCredentialStore = writablePath;
|
|
148
|
+
}
|
|
107
149
|
//#endregion
|
|
108
150
|
export { commitAndPushNodeRef, mergeDependencyRefs, prepareRunnerGitWorkspace, promoteFinalRef };
|
|
@@ -43,8 +43,8 @@ declare const runnerDeliverySchema: z.ZodObject<{
|
|
|
43
43
|
declare const mokaSubmissionSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
44
44
|
kind: z.ZodLiteral<"graph">;
|
|
45
45
|
mode: z.ZodEnum<{
|
|
46
|
-
quick: "quick";
|
|
47
46
|
full: "full";
|
|
47
|
+
quick: "quick";
|
|
48
48
|
}>;
|
|
49
49
|
}, z.core.$strict>, z.ZodObject<{
|
|
50
50
|
argv: z.ZodArray<z.ZodString>;
|
|
@@ -104,8 +104,8 @@ declare const runnerCommandPayloadSchema: z.ZodObject<{
|
|
|
104
104
|
submission: z.ZodDefault<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
105
105
|
kind: z.ZodLiteral<"graph">;
|
|
106
106
|
mode: z.ZodEnum<{
|
|
107
|
-
quick: "quick";
|
|
108
107
|
full: "full";
|
|
108
|
+
quick: "quick";
|
|
109
109
|
}>;
|
|
110
110
|
}, z.core.$strict>, z.ZodObject<{
|
|
111
111
|
argv: z.ZodArray<z.ZodString>;
|
package/package.json
CHANGED
|
@@ -120,7 +120,7 @@
|
|
|
120
120
|
"prepack": "bun run build:cli"
|
|
121
121
|
},
|
|
122
122
|
"type": "module",
|
|
123
|
-
"version": "1.27.
|
|
123
|
+
"version": "1.27.10",
|
|
124
124
|
"description": "Config-driven multi-agent pipeline runner for repository work",
|
|
125
125
|
"main": "./dist/index.js",
|
|
126
126
|
"types": "./dist/index.d.ts",
|