@kitsi/action 0.0.15 → 0.0.16
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.js +155 -316
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -101119,7 +101119,7 @@ var require_picomatch2 = __commonJS((exports, module2) => {
|
|
|
101119
101119
|
});
|
|
101120
101120
|
|
|
101121
101121
|
// src/index.ts
|
|
101122
|
-
var
|
|
101122
|
+
var core7 = __toESM(require_core(), 1);
|
|
101123
101123
|
|
|
101124
101124
|
// src/capabilities/annotations.ts
|
|
101125
101125
|
var core = __toESM(require_core(), 1);
|
|
@@ -101566,9 +101566,9 @@ class GroupManager {
|
|
|
101566
101566
|
import { resolve as resolvePath2 } from "node:path";
|
|
101567
101567
|
import { pathToFileURL } from "node:url";
|
|
101568
101568
|
|
|
101569
|
-
// ../
|
|
101569
|
+
// ../core/dist/version.js
|
|
101570
101570
|
var VERSION = "0.0.1";
|
|
101571
|
-
// ../
|
|
101571
|
+
// ../core/dist/dsl/plan.js
|
|
101572
101572
|
var clonePlan = (plan, patch) => new PlanBuilder((() => {
|
|
101573
101573
|
const next = {
|
|
101574
101574
|
name: patch.name ?? plan.config.name,
|
|
@@ -101662,7 +101662,7 @@ var plan = (name) => new PlanBuilder({
|
|
|
101662
101662
|
concurrency: {},
|
|
101663
101663
|
tasks: []
|
|
101664
101664
|
});
|
|
101665
|
-
// ../
|
|
101665
|
+
// ../core/dist/dsl/task.js
|
|
101666
101666
|
var cloneTask = (task, patch) => new TaskBuilder({
|
|
101667
101667
|
...task.config,
|
|
101668
101668
|
...patch,
|
|
@@ -101729,7 +101729,7 @@ var task = (name) => new TaskBuilder({
|
|
|
101729
101729
|
inputs: [],
|
|
101730
101730
|
cacheEnv: []
|
|
101731
101731
|
});
|
|
101732
|
-
// ../
|
|
101732
|
+
// ../core/dist/dsl/step.js
|
|
101733
101733
|
class StepBuilder {
|
|
101734
101734
|
name;
|
|
101735
101735
|
run;
|
|
@@ -101746,7 +101746,7 @@ class StepBuilder {
|
|
|
101746
101746
|
}
|
|
101747
101747
|
}
|
|
101748
101748
|
var step = (name, run) => new StepBuilder(name, run);
|
|
101749
|
-
// ../
|
|
101749
|
+
// ../core/dist/dsl/kit.js
|
|
101750
101750
|
var cloneKit = (kit, patch) => new KitBuilder({
|
|
101751
101751
|
...kit.config,
|
|
101752
101752
|
...patch,
|
|
@@ -101780,7 +101780,7 @@ class KitBuilder {
|
|
|
101780
101780
|
}
|
|
101781
101781
|
}
|
|
101782
101782
|
var kit = (name) => new KitBuilder({ name, env: {}, setupSteps: [] });
|
|
101783
|
-
// ../
|
|
101783
|
+
// ../core/dist/dsl/image.js
|
|
101784
101784
|
class ImageBuilder {
|
|
101785
101785
|
config;
|
|
101786
101786
|
constructor(config) {
|
|
@@ -101794,7 +101794,7 @@ class ImageBuilder {
|
|
|
101794
101794
|
}
|
|
101795
101795
|
}
|
|
101796
101796
|
var image = (ref) => new ImageBuilder({ ref, env: {} });
|
|
101797
|
-
// ../
|
|
101797
|
+
// ../core/dist/dsl/service.js
|
|
101798
101798
|
class ServiceBuilder {
|
|
101799
101799
|
config;
|
|
101800
101800
|
constructor(config) {
|
|
@@ -101814,11 +101814,11 @@ class ServiceBuilder {
|
|
|
101814
101814
|
}
|
|
101815
101815
|
}
|
|
101816
101816
|
var service = (imageRef) => new ServiceBuilder({ image: imageRef, env: {}, ports: [] });
|
|
101817
|
-
// ../
|
|
101817
|
+
// ../core/dist/dsl/registry.js
|
|
101818
101818
|
var registry = (...plansList) => ({
|
|
101819
101819
|
plans: plansList
|
|
101820
101820
|
});
|
|
101821
|
-
// ../
|
|
101821
|
+
// ../core/dist/ops/operation.js
|
|
101822
101822
|
var isOperation = (value) => {
|
|
101823
101823
|
if (!value || typeof value !== "object")
|
|
101824
101824
|
return false;
|
|
@@ -101826,7 +101826,7 @@ var isOperation = (value) => {
|
|
|
101826
101826
|
return typeof op.kind === "string" && typeof op.toOp === "function" && typeof op.analysisPlaceholder === "function" && typeof op.extractDependencies === "function" && typeof op.extractSecrets === "function" && typeof op.extractRefs === "function" && typeof op.cacheNormalize === "function" && typeof op.cachePlaceholder === "function";
|
|
101827
101827
|
};
|
|
101828
101828
|
|
|
101829
|
-
// ../
|
|
101829
|
+
// ../core/dist/dsl/analysis.js
|
|
101830
101830
|
var stepIterator = (step2, task2) => {
|
|
101831
101831
|
return step2.run({ task: task2, workspace: "" });
|
|
101832
101832
|
};
|
|
@@ -101864,14 +101864,14 @@ var collectSecrets = (tasks) => {
|
|
|
101864
101864
|
}
|
|
101865
101865
|
return secrets;
|
|
101866
101866
|
};
|
|
101867
|
-
// ../
|
|
101867
|
+
// ../core/dist/dsl/utils.js
|
|
101868
101868
|
import { resolve as resolvePath } from "node:path";
|
|
101869
101869
|
var resolveWorkspace = (workspace) => {
|
|
101870
101870
|
if (!workspace)
|
|
101871
101871
|
return process.cwd();
|
|
101872
101872
|
return workspace.startsWith(".") ? resolvePath(process.cwd(), workspace) : workspace;
|
|
101873
101873
|
};
|
|
101874
|
-
// ../
|
|
101874
|
+
// ../core/dist/ops/errors.js
|
|
101875
101875
|
class OpErrorBuilder {
|
|
101876
101876
|
type;
|
|
101877
101877
|
message;
|
|
@@ -101912,7 +101912,9 @@ var OpErrors = {
|
|
|
101912
101912
|
service: (message) => new OpErrorBuilder("service", message),
|
|
101913
101913
|
timeout: (message) => new OpErrorBuilder("timeout", message)
|
|
101914
101914
|
};
|
|
101915
|
-
// ../
|
|
101915
|
+
// ../core/dist/ops/template.js
|
|
101916
|
+
var isTemplateStringsArray = (value) => Array.isArray(value) && Object.prototype.hasOwnProperty.call(value, "raw");
|
|
101917
|
+
var isTemplatePartArray = (value) => Array.isArray(value) && (value.length === 0 || typeof value[0] === "object" && value[0] !== null && ("type" in value[0]));
|
|
101916
101918
|
var toTemplatePart = (value) => {
|
|
101917
101919
|
if (typeof value === "string" || typeof value === "number") {
|
|
101918
101920
|
return { type: "interpolated", value: String(value) };
|
|
@@ -101925,6 +101927,32 @@ var toTemplatePart = (value) => {
|
|
|
101925
101927
|
}
|
|
101926
101928
|
return { type: "value", ref: value };
|
|
101927
101929
|
};
|
|
101930
|
+
var buildTemplateParts = (strings, values) => {
|
|
101931
|
+
const template = [];
|
|
101932
|
+
for (let i = 0;i < strings.length; i += 1) {
|
|
101933
|
+
const text = strings[i] ?? "";
|
|
101934
|
+
if (text.length > 0) {
|
|
101935
|
+
template.push({ type: "text", value: text });
|
|
101936
|
+
}
|
|
101937
|
+
const value = values[i];
|
|
101938
|
+
if (i < values.length && value !== undefined) {
|
|
101939
|
+
template.push(toTemplatePart(value));
|
|
101940
|
+
}
|
|
101941
|
+
}
|
|
101942
|
+
return template;
|
|
101943
|
+
};
|
|
101944
|
+
var templateFromInput = (input, values) => {
|
|
101945
|
+
if (isTemplateStringsArray(input)) {
|
|
101946
|
+
return buildTemplateParts(input, values);
|
|
101947
|
+
}
|
|
101948
|
+
if (isTemplatePartArray(input)) {
|
|
101949
|
+
return input;
|
|
101950
|
+
}
|
|
101951
|
+
if (Array.isArray(input)) {
|
|
101952
|
+
return input.map((part) => toTemplatePart(part));
|
|
101953
|
+
}
|
|
101954
|
+
return [toTemplatePart(input)];
|
|
101955
|
+
};
|
|
101928
101956
|
var collectTemplateMetadata = (template, addSecret, addParam) => {
|
|
101929
101957
|
for (const part of template) {
|
|
101930
101958
|
if (part.type === "secret")
|
|
@@ -101933,6 +101961,14 @@ var collectTemplateMetadata = (template, addSecret, addParam) => {
|
|
|
101933
101961
|
addParam(part.ref.name);
|
|
101934
101962
|
}
|
|
101935
101963
|
};
|
|
101964
|
+
var collectTemplateSecrets = (template) => {
|
|
101965
|
+
const names = new Set;
|
|
101966
|
+
for (const part of template) {
|
|
101967
|
+
if (part.type === "secret")
|
|
101968
|
+
names.add(part.name);
|
|
101969
|
+
}
|
|
101970
|
+
return Array.from(names);
|
|
101971
|
+
};
|
|
101936
101972
|
var normalizeTemplatePart = (part) => {
|
|
101937
101973
|
if (part.type === "text" || part.type === "interpolated") {
|
|
101938
101974
|
return { type: part.type, value: part.value };
|
|
@@ -101957,6 +101993,7 @@ var commandSignature = (template) => {
|
|
|
101957
101993
|
return raw.replace(/\s+/g, " ").trim();
|
|
101958
101994
|
};
|
|
101959
101995
|
|
|
101996
|
+
// ../core/dist/ops/shell.js
|
|
101960
101997
|
class CommandBuilder {
|
|
101961
101998
|
op;
|
|
101962
101999
|
constructor(op) {
|
|
@@ -102021,90 +102058,15 @@ class CommandBuilder {
|
|
|
102021
102058
|
}
|
|
102022
102059
|
}
|
|
102023
102060
|
var sh = (strings, ...values) => {
|
|
102024
|
-
const template =
|
|
102025
|
-
for (let i = 0;i < strings.length; i += 1) {
|
|
102026
|
-
const text = strings[i] ?? "";
|
|
102027
|
-
if (text.length > 0) {
|
|
102028
|
-
template.push({ type: "text", value: text });
|
|
102029
|
-
}
|
|
102030
|
-
const value = values[i];
|
|
102031
|
-
if (i < values.length && value !== undefined) {
|
|
102032
|
-
template.push(toTemplatePart(value));
|
|
102033
|
-
}
|
|
102034
|
-
}
|
|
102061
|
+
const template = buildTemplateParts(strings, values);
|
|
102035
102062
|
return new CommandBuilder({
|
|
102036
102063
|
kind: "command",
|
|
102037
102064
|
capture: "result",
|
|
102038
102065
|
template
|
|
102039
102066
|
});
|
|
102040
102067
|
};
|
|
102041
|
-
// ../
|
|
102042
|
-
var isTemplateStringsArray = (value) => Array.isArray(value) && Object.prototype.hasOwnProperty.call(value, "raw");
|
|
102043
|
-
var isTemplatePartArray = (value) => Array.isArray(value) && (value.length === 0 || typeof value[0] === "object" && value[0] !== null && ("type" in value[0]));
|
|
102044
|
-
var toTemplatePart2 = (value) => {
|
|
102045
|
-
if (typeof value === "string" || typeof value === "number") {
|
|
102046
|
-
return { type: "interpolated", value: String(value) };
|
|
102047
|
-
}
|
|
102048
|
-
if (value.kind === "secret") {
|
|
102049
|
-
return { type: "secret", name: value.name };
|
|
102050
|
-
}
|
|
102051
|
-
if (value.kind === "param") {
|
|
102052
|
-
return { type: "param", ref: value };
|
|
102053
|
-
}
|
|
102054
|
-
return { type: "value", ref: value };
|
|
102055
|
-
};
|
|
102056
|
-
var buildTemplateParts = (strings, values) => {
|
|
102057
|
-
const template = [];
|
|
102058
|
-
for (let i = 0;i < strings.length; i += 1) {
|
|
102059
|
-
const text = strings[i] ?? "";
|
|
102060
|
-
if (text.length > 0) {
|
|
102061
|
-
template.push({ type: "text", value: text });
|
|
102062
|
-
}
|
|
102063
|
-
const value = values[i];
|
|
102064
|
-
if (i < values.length && value !== undefined) {
|
|
102065
|
-
template.push(toTemplatePart2(value));
|
|
102066
|
-
}
|
|
102067
|
-
}
|
|
102068
|
-
return template;
|
|
102069
|
-
};
|
|
102070
|
-
var templateFromInput = (input, values) => {
|
|
102071
|
-
if (isTemplateStringsArray(input)) {
|
|
102072
|
-
return buildTemplateParts(input, values);
|
|
102073
|
-
}
|
|
102074
|
-
if (isTemplatePartArray(input)) {
|
|
102075
|
-
return input;
|
|
102076
|
-
}
|
|
102077
|
-
if (Array.isArray(input)) {
|
|
102078
|
-
return input.map((part) => toTemplatePart2(part));
|
|
102079
|
-
}
|
|
102080
|
-
return [toTemplatePart2(input)];
|
|
102081
|
-
};
|
|
102068
|
+
// ../core/dist/ops/http.js
|
|
102082
102069
|
var hasHeader = (headers, name) => headers.some((header) => header.name.toLowerCase() === name.toLowerCase());
|
|
102083
|
-
var collectTemplateSecrets = (template) => {
|
|
102084
|
-
const names = new Set;
|
|
102085
|
-
for (const part of template) {
|
|
102086
|
-
if (part.type === "secret")
|
|
102087
|
-
names.add(part.name);
|
|
102088
|
-
}
|
|
102089
|
-
return Array.from(names);
|
|
102090
|
-
};
|
|
102091
|
-
var collectTemplateMetadata2 = (template, addSecret, addParam) => {
|
|
102092
|
-
for (const part of template) {
|
|
102093
|
-
if (part.type === "secret")
|
|
102094
|
-
addSecret(part.name);
|
|
102095
|
-
if (part.type === "param")
|
|
102096
|
-
addParam(part.ref.name);
|
|
102097
|
-
}
|
|
102098
|
-
};
|
|
102099
|
-
var normalizeTemplatePart2 = (part) => {
|
|
102100
|
-
if (part.type === "text" || part.type === "interpolated") {
|
|
102101
|
-
return { type: part.type, value: part.value };
|
|
102102
|
-
}
|
|
102103
|
-
if (part.type === "secret") {
|
|
102104
|
-
return { type: part.type, name: part.name };
|
|
102105
|
-
}
|
|
102106
|
-
return { type: part.type, name: part.ref.name };
|
|
102107
|
-
};
|
|
102108
102070
|
|
|
102109
102071
|
class HttpBuilder {
|
|
102110
102072
|
op;
|
|
@@ -102141,22 +102103,22 @@ class HttpBuilder {
|
|
|
102141
102103
|
return [];
|
|
102142
102104
|
}
|
|
102143
102105
|
cacheNormalize(context) {
|
|
102144
|
-
|
|
102106
|
+
collectTemplateMetadata(this.op.url, context.addSecret, context.addParam);
|
|
102145
102107
|
for (const header of this.op.headers) {
|
|
102146
|
-
|
|
102108
|
+
collectTemplateMetadata(header.value, context.addSecret, context.addParam);
|
|
102147
102109
|
}
|
|
102148
102110
|
if (this.op.body) {
|
|
102149
|
-
|
|
102111
|
+
collectTemplateMetadata(this.op.body, context.addSecret, context.addParam);
|
|
102150
102112
|
}
|
|
102151
102113
|
return {
|
|
102152
102114
|
kind: this.op.kind,
|
|
102153
102115
|
method: this.op.method,
|
|
102154
|
-
url: this.op.url.map(
|
|
102116
|
+
url: this.op.url.map(normalizeTemplatePart),
|
|
102155
102117
|
headers: this.op.headers.map((header) => ({
|
|
102156
102118
|
name: header.name,
|
|
102157
|
-
value: header.value.map(
|
|
102119
|
+
value: header.value.map(normalizeTemplatePart)
|
|
102158
102120
|
})),
|
|
102159
|
-
body: this.op.body ? this.op.body.map(
|
|
102121
|
+
body: this.op.body ? this.op.body.map(normalizeTemplatePart) : null,
|
|
102160
102122
|
bodyPath: this.op.bodyPath ?? null
|
|
102161
102123
|
};
|
|
102162
102124
|
}
|
|
@@ -102211,12 +102173,12 @@ var http = {
|
|
|
102211
102173
|
head: (url, ...values) => buildRequest("HEAD", url, values),
|
|
102212
102174
|
options: (url, ...values) => buildRequest("OPTIONS", url, values)
|
|
102213
102175
|
};
|
|
102214
|
-
// ../
|
|
102176
|
+
// ../core/dist/ops/types.js
|
|
102215
102177
|
var isSecretRef = (value) => value.kind === "secret";
|
|
102216
102178
|
var isParamRef = (value) => value.kind === "param";
|
|
102217
102179
|
var isValueRef = (value) => value.kind === "value";
|
|
102218
102180
|
|
|
102219
|
-
// ../
|
|
102181
|
+
// ../core/dist/ops/env.js
|
|
102220
102182
|
class EnvOperation {
|
|
102221
102183
|
name;
|
|
102222
102184
|
value;
|
|
@@ -102278,9 +102240,9 @@ class EnvOperation {
|
|
|
102278
102240
|
}
|
|
102279
102241
|
}
|
|
102280
102242
|
var env = (name, value) => new EnvOperation(name, value);
|
|
102281
|
-
// ../
|
|
102243
|
+
// ../core/dist/ops/secret.js
|
|
102282
102244
|
var secret = (name) => ({ kind: "secret", name });
|
|
102283
|
-
// ../
|
|
102245
|
+
// ../core/dist/ops/ref.js
|
|
102284
102246
|
var coerce = {
|
|
102285
102247
|
string: (value) => String(value),
|
|
102286
102248
|
number: (value) => Number(value),
|
|
@@ -102302,12 +102264,32 @@ var createRefFactory = (kind) => {
|
|
|
102302
102264
|
};
|
|
102303
102265
|
var param = createRefFactory("param");
|
|
102304
102266
|
var out = createRefFactory("value");
|
|
102305
|
-
// ../
|
|
102306
|
-
class
|
|
102267
|
+
// ../core/dist/ops/operation-base.js
|
|
102268
|
+
class OperationBase {
|
|
102269
|
+
analysisPlaceholder() {
|
|
102270
|
+
return;
|
|
102271
|
+
}
|
|
102272
|
+
extractDependencies(_taskName) {
|
|
102273
|
+
return [];
|
|
102274
|
+
}
|
|
102275
|
+
extractSecrets() {
|
|
102276
|
+
return [];
|
|
102277
|
+
}
|
|
102278
|
+
extractRefs() {
|
|
102279
|
+
return [];
|
|
102280
|
+
}
|
|
102281
|
+
cachePlaceholder(context) {
|
|
102282
|
+
return context.value;
|
|
102283
|
+
}
|
|
102284
|
+
}
|
|
102285
|
+
|
|
102286
|
+
// ../core/dist/ops/cache.js
|
|
102287
|
+
class CacheOperation extends OperationBase {
|
|
102307
102288
|
name;
|
|
102308
102289
|
paths;
|
|
102309
102290
|
key;
|
|
102310
102291
|
constructor(name, paths, key) {
|
|
102292
|
+
super();
|
|
102311
102293
|
this.name = name;
|
|
102312
102294
|
this.paths = paths;
|
|
102313
102295
|
if (key)
|
|
@@ -102324,18 +102306,6 @@ class CacheOperation {
|
|
|
102324
102306
|
...this.key ? { key: this.key } : {}
|
|
102325
102307
|
};
|
|
102326
102308
|
}
|
|
102327
|
-
analysisPlaceholder() {
|
|
102328
|
-
return;
|
|
102329
|
-
}
|
|
102330
|
-
extractDependencies(_taskName) {
|
|
102331
|
-
return [];
|
|
102332
|
-
}
|
|
102333
|
-
extractSecrets() {
|
|
102334
|
-
return [];
|
|
102335
|
-
}
|
|
102336
|
-
extractRefs() {
|
|
102337
|
-
return [];
|
|
102338
|
-
}
|
|
102339
102309
|
cacheNormalize(_context) {
|
|
102340
102310
|
return {
|
|
102341
102311
|
kind: this.kind,
|
|
@@ -102344,17 +102314,15 @@ class CacheOperation {
|
|
|
102344
102314
|
key: this.key ?? null
|
|
102345
102315
|
};
|
|
102346
102316
|
}
|
|
102347
|
-
cachePlaceholder(context) {
|
|
102348
|
-
return context.value;
|
|
102349
|
-
}
|
|
102350
102317
|
}
|
|
102351
102318
|
|
|
102352
|
-
class CacheOrOperation {
|
|
102319
|
+
class CacheOrOperation extends OperationBase {
|
|
102353
102320
|
name;
|
|
102354
102321
|
paths;
|
|
102355
102322
|
key;
|
|
102356
102323
|
compute;
|
|
102357
102324
|
constructor(name, paths, compute, key) {
|
|
102325
|
+
super();
|
|
102358
102326
|
this.name = name;
|
|
102359
102327
|
this.paths = paths;
|
|
102360
102328
|
this.compute = compute;
|
|
@@ -102373,18 +102341,6 @@ class CacheOrOperation {
|
|
|
102373
102341
|
compute: this.compute
|
|
102374
102342
|
};
|
|
102375
102343
|
}
|
|
102376
|
-
analysisPlaceholder() {
|
|
102377
|
-
return;
|
|
102378
|
-
}
|
|
102379
|
-
extractDependencies(_taskName) {
|
|
102380
|
-
return [];
|
|
102381
|
-
}
|
|
102382
|
-
extractSecrets() {
|
|
102383
|
-
return [];
|
|
102384
|
-
}
|
|
102385
|
-
extractRefs() {
|
|
102386
|
-
return [];
|
|
102387
|
-
}
|
|
102388
102344
|
cacheNormalize(context) {
|
|
102389
102345
|
const computeOps = context.analyzeNested(this.compute, context.resultValue);
|
|
102390
102346
|
return {
|
|
@@ -102395,14 +102351,12 @@ class CacheOrOperation {
|
|
|
102395
102351
|
compute: computeOps
|
|
102396
102352
|
};
|
|
102397
102353
|
}
|
|
102398
|
-
cachePlaceholder(context) {
|
|
102399
|
-
return context.value;
|
|
102400
|
-
}
|
|
102401
102354
|
}
|
|
102402
102355
|
|
|
102403
|
-
class CacheMountOperation {
|
|
102356
|
+
class CacheMountOperation extends OperationBase {
|
|
102404
102357
|
cache;
|
|
102405
102358
|
constructor(cache2) {
|
|
102359
|
+
super();
|
|
102406
102360
|
this.cache = cache2;
|
|
102407
102361
|
}
|
|
102408
102362
|
get kind() {
|
|
@@ -102411,24 +102365,9 @@ class CacheMountOperation {
|
|
|
102411
102365
|
toOp() {
|
|
102412
102366
|
return { kind: "cache-mount", cache: this.cache };
|
|
102413
102367
|
}
|
|
102414
|
-
analysisPlaceholder() {
|
|
102415
|
-
return;
|
|
102416
|
-
}
|
|
102417
|
-
extractDependencies(_taskName) {
|
|
102418
|
-
return [];
|
|
102419
|
-
}
|
|
102420
|
-
extractSecrets() {
|
|
102421
|
-
return [];
|
|
102422
|
-
}
|
|
102423
|
-
extractRefs() {
|
|
102424
|
-
return [];
|
|
102425
|
-
}
|
|
102426
102368
|
cacheNormalize(_context) {
|
|
102427
102369
|
return { kind: this.kind };
|
|
102428
102370
|
}
|
|
102429
|
-
cachePlaceholder(context) {
|
|
102430
|
-
return context.value;
|
|
102431
|
-
}
|
|
102432
102371
|
}
|
|
102433
102372
|
var createCacheRef = (name, mountPath, key) => {
|
|
102434
102373
|
const ref = {
|
|
@@ -102448,12 +102387,13 @@ var cacheFn = (name, options) => new CacheOperation(name, options.paths, options
|
|
|
102448
102387
|
cacheFn.dir = (name) => createCacheRef(name);
|
|
102449
102388
|
cacheFn.mount = (ref) => new CacheMountOperation(ref);
|
|
102450
102389
|
var cache2 = cacheFn;
|
|
102451
|
-
// ../
|
|
102452
|
-
class ArtifactUploadOperation {
|
|
102390
|
+
// ../core/dist/ops/artifact.js
|
|
102391
|
+
class ArtifactUploadOperation extends OperationBase {
|
|
102453
102392
|
name;
|
|
102454
102393
|
patterns;
|
|
102455
102394
|
when;
|
|
102456
102395
|
constructor(name, patterns, when) {
|
|
102396
|
+
super();
|
|
102457
102397
|
this.name = name;
|
|
102458
102398
|
this.patterns = patterns;
|
|
102459
102399
|
this.when = when;
|
|
@@ -102464,18 +102404,6 @@ class ArtifactUploadOperation {
|
|
|
102464
102404
|
toOp() {
|
|
102465
102405
|
return { kind: "artifact-upload", name: this.name, patterns: this.patterns, when: this.when };
|
|
102466
102406
|
}
|
|
102467
|
-
analysisPlaceholder() {
|
|
102468
|
-
return;
|
|
102469
|
-
}
|
|
102470
|
-
extractDependencies(_taskName) {
|
|
102471
|
-
return [];
|
|
102472
|
-
}
|
|
102473
|
-
extractSecrets() {
|
|
102474
|
-
return [];
|
|
102475
|
-
}
|
|
102476
|
-
extractRefs() {
|
|
102477
|
-
return [];
|
|
102478
|
-
}
|
|
102479
102407
|
cacheNormalize(_context) {
|
|
102480
102408
|
return {
|
|
102481
102409
|
kind: this.kind,
|
|
@@ -102484,15 +102412,13 @@ class ArtifactUploadOperation {
|
|
|
102484
102412
|
when: this.when
|
|
102485
102413
|
};
|
|
102486
102414
|
}
|
|
102487
|
-
cachePlaceholder(context) {
|
|
102488
|
-
return context.value;
|
|
102489
|
-
}
|
|
102490
102415
|
}
|
|
102491
102416
|
|
|
102492
|
-
class ArtifactDownloadOperation {
|
|
102417
|
+
class ArtifactDownloadOperation extends OperationBase {
|
|
102493
102418
|
name;
|
|
102494
102419
|
destination;
|
|
102495
102420
|
constructor(name, destination) {
|
|
102421
|
+
super();
|
|
102496
102422
|
this.name = name;
|
|
102497
102423
|
this.destination = destination;
|
|
102498
102424
|
}
|
|
@@ -102502,24 +102428,9 @@ class ArtifactDownloadOperation {
|
|
|
102502
102428
|
toOp() {
|
|
102503
102429
|
return { kind: "artifact-download", name: this.name, destination: this.destination };
|
|
102504
102430
|
}
|
|
102505
|
-
analysisPlaceholder() {
|
|
102506
|
-
return;
|
|
102507
|
-
}
|
|
102508
|
-
extractDependencies(_taskName) {
|
|
102509
|
-
return [];
|
|
102510
|
-
}
|
|
102511
|
-
extractSecrets() {
|
|
102512
|
-
return [];
|
|
102513
|
-
}
|
|
102514
|
-
extractRefs() {
|
|
102515
|
-
return [];
|
|
102516
|
-
}
|
|
102517
102431
|
cacheNormalize(_context) {
|
|
102518
102432
|
return { kind: this.kind, name: this.name, destination: this.destination };
|
|
102519
102433
|
}
|
|
102520
|
-
cachePlaceholder(context) {
|
|
102521
|
-
return context.value;
|
|
102522
|
-
}
|
|
102523
102434
|
}
|
|
102524
102435
|
|
|
102525
102436
|
class ArtifactUploadBuilder {
|
|
@@ -102555,7 +102466,7 @@ var artifact2 = {
|
|
|
102555
102466
|
upload: (name) => new ArtifactUploadBuilder(name),
|
|
102556
102467
|
download: (name) => new ArtifactDownloadBuilder(name)
|
|
102557
102468
|
};
|
|
102558
|
-
// ../
|
|
102469
|
+
// ../core/dist/ops/bundle.js
|
|
102559
102470
|
var cloneBundle = (ref, patterns) => ({
|
|
102560
102471
|
...ref,
|
|
102561
102472
|
patterns,
|
|
@@ -102571,9 +102482,10 @@ var createBundleRef = (name) => {
|
|
|
102571
102482
|
return ref;
|
|
102572
102483
|
};
|
|
102573
102484
|
|
|
102574
|
-
class PackOperation {
|
|
102485
|
+
class PackOperation extends OperationBase {
|
|
102575
102486
|
ref;
|
|
102576
102487
|
constructor(ref) {
|
|
102488
|
+
super();
|
|
102577
102489
|
this.ref = ref;
|
|
102578
102490
|
}
|
|
102579
102491
|
get kind() {
|
|
@@ -102582,18 +102494,6 @@ class PackOperation {
|
|
|
102582
102494
|
toOp() {
|
|
102583
102495
|
return { kind: "pack", ref: this.ref };
|
|
102584
102496
|
}
|
|
102585
|
-
analysisPlaceholder() {
|
|
102586
|
-
return;
|
|
102587
|
-
}
|
|
102588
|
-
extractDependencies(_taskName) {
|
|
102589
|
-
return [];
|
|
102590
|
-
}
|
|
102591
|
-
extractSecrets() {
|
|
102592
|
-
return [];
|
|
102593
|
-
}
|
|
102594
|
-
extractRefs() {
|
|
102595
|
-
return [];
|
|
102596
|
-
}
|
|
102597
102497
|
cacheNormalize(_context) {
|
|
102598
102498
|
return { kind: this.kind, name: this.ref.name, patterns: this.ref.patterns };
|
|
102599
102499
|
}
|
|
@@ -102602,10 +102502,11 @@ class PackOperation {
|
|
|
102602
102502
|
}
|
|
102603
102503
|
}
|
|
102604
102504
|
|
|
102605
|
-
class UnpackOperation {
|
|
102505
|
+
class UnpackOperation extends OperationBase {
|
|
102606
102506
|
from;
|
|
102607
102507
|
ref;
|
|
102608
102508
|
constructor(from, ref) {
|
|
102509
|
+
super();
|
|
102609
102510
|
this.from = from;
|
|
102610
102511
|
this.ref = ref;
|
|
102611
102512
|
}
|
|
@@ -102615,15 +102516,9 @@ class UnpackOperation {
|
|
|
102615
102516
|
toOp() {
|
|
102616
102517
|
return { kind: "unpack", from: this.from, ref: this.ref };
|
|
102617
102518
|
}
|
|
102618
|
-
analysisPlaceholder() {
|
|
102619
|
-
return;
|
|
102620
|
-
}
|
|
102621
102519
|
extractDependencies(taskName) {
|
|
102622
102520
|
return [{ from: this.from.config.name, to: taskName, type: "unpack" }];
|
|
102623
102521
|
}
|
|
102624
|
-
extractSecrets() {
|
|
102625
|
-
return [];
|
|
102626
|
-
}
|
|
102627
102522
|
extractRefs() {
|
|
102628
102523
|
return [{ type: "bundle", ref: this.ref }];
|
|
102629
102524
|
}
|
|
@@ -102643,7 +102538,7 @@ class UnpackOperation {
|
|
|
102643
102538
|
var pack = (ref) => new PackOperation(ref);
|
|
102644
102539
|
var unpack = (from, ref) => new UnpackOperation(from, ref);
|
|
102645
102540
|
|
|
102646
|
-
// ../
|
|
102541
|
+
// ../core/dist/ops/output.js
|
|
102647
102542
|
var out2 = {
|
|
102648
102543
|
...out,
|
|
102649
102544
|
bundle: (name) => createBundleRef(name)
|
|
@@ -102717,11 +102612,12 @@ class UseOperation {
|
|
|
102717
102612
|
return context.isPrimary ? this.ref.parse("") : undefined;
|
|
102718
102613
|
}
|
|
102719
102614
|
}
|
|
102720
|
-
// ../
|
|
102721
|
-
class SummaryOperation {
|
|
102615
|
+
// ../core/dist/ops/summary.js
|
|
102616
|
+
class SummaryOperation extends OperationBase {
|
|
102722
102617
|
format;
|
|
102723
102618
|
content;
|
|
102724
102619
|
constructor(format, content) {
|
|
102620
|
+
super();
|
|
102725
102621
|
this.format = format;
|
|
102726
102622
|
this.content = content;
|
|
102727
102623
|
}
|
|
@@ -102731,34 +102627,20 @@ class SummaryOperation {
|
|
|
102731
102627
|
toOp() {
|
|
102732
102628
|
return { kind: "summary", format: this.format, content: this.content };
|
|
102733
102629
|
}
|
|
102734
|
-
analysisPlaceholder() {
|
|
102735
|
-
return;
|
|
102736
|
-
}
|
|
102737
|
-
extractDependencies(_taskName) {
|
|
102738
|
-
return [];
|
|
102739
|
-
}
|
|
102740
|
-
extractSecrets() {
|
|
102741
|
-
return [];
|
|
102742
|
-
}
|
|
102743
|
-
extractRefs() {
|
|
102744
|
-
return [];
|
|
102745
|
-
}
|
|
102746
102630
|
cacheNormalize(_context) {
|
|
102747
102631
|
return { kind: this.kind, format: this.format, content: this.content };
|
|
102748
102632
|
}
|
|
102749
|
-
cachePlaceholder(context) {
|
|
102750
|
-
return context.value;
|
|
102751
|
-
}
|
|
102752
102633
|
}
|
|
102753
102634
|
var summary2 = {
|
|
102754
102635
|
md: (content) => new SummaryOperation("md", content)
|
|
102755
102636
|
};
|
|
102756
|
-
// ../
|
|
102757
|
-
class AnnotateOperation {
|
|
102637
|
+
// ../core/dist/ops/annotate.js
|
|
102638
|
+
class AnnotateOperation extends OperationBase {
|
|
102758
102639
|
level;
|
|
102759
102640
|
message;
|
|
102760
102641
|
location;
|
|
102761
102642
|
constructor(level, message, location) {
|
|
102643
|
+
super();
|
|
102762
102644
|
this.level = level;
|
|
102763
102645
|
this.message = message;
|
|
102764
102646
|
if (location)
|
|
@@ -102775,24 +102657,9 @@ class AnnotateOperation {
|
|
|
102775
102657
|
...this.location ? { location: this.location } : {}
|
|
102776
102658
|
};
|
|
102777
102659
|
}
|
|
102778
|
-
analysisPlaceholder() {
|
|
102779
|
-
return;
|
|
102780
|
-
}
|
|
102781
|
-
extractDependencies(_taskName) {
|
|
102782
|
-
return [];
|
|
102783
|
-
}
|
|
102784
|
-
extractSecrets() {
|
|
102785
|
-
return [];
|
|
102786
|
-
}
|
|
102787
|
-
extractRefs() {
|
|
102788
|
-
return [];
|
|
102789
|
-
}
|
|
102790
102660
|
cacheNormalize(_context) {
|
|
102791
102661
|
return { kind: this.kind, level: this.level, message: this.message };
|
|
102792
102662
|
}
|
|
102793
|
-
cachePlaceholder(context) {
|
|
102794
|
-
return context.value;
|
|
102795
|
-
}
|
|
102796
102663
|
}
|
|
102797
102664
|
var createAnnotation = (level) => (message, location) => new AnnotateOperation(level, message, location);
|
|
102798
102665
|
var annotate = {
|
|
@@ -102800,11 +102667,12 @@ var annotate = {
|
|
|
102800
102667
|
warning: createAnnotation("warning"),
|
|
102801
102668
|
info: createAnnotation("info")
|
|
102802
102669
|
};
|
|
102803
|
-
// ../
|
|
102804
|
-
class ReportOperation {
|
|
102670
|
+
// ../core/dist/ops/report.js
|
|
102671
|
+
class ReportOperation extends OperationBase {
|
|
102805
102672
|
reportType;
|
|
102806
102673
|
path;
|
|
102807
102674
|
constructor(reportType, path) {
|
|
102675
|
+
super();
|
|
102808
102676
|
this.reportType = reportType;
|
|
102809
102677
|
this.path = path;
|
|
102810
102678
|
}
|
|
@@ -102814,34 +102682,20 @@ class ReportOperation {
|
|
|
102814
102682
|
toOp() {
|
|
102815
102683
|
return { kind: "report", reportType: this.reportType, path: this.path };
|
|
102816
102684
|
}
|
|
102817
|
-
analysisPlaceholder() {
|
|
102818
|
-
return;
|
|
102819
|
-
}
|
|
102820
|
-
extractDependencies(_taskName) {
|
|
102821
|
-
return [];
|
|
102822
|
-
}
|
|
102823
|
-
extractSecrets() {
|
|
102824
|
-
return [];
|
|
102825
|
-
}
|
|
102826
|
-
extractRefs() {
|
|
102827
|
-
return [];
|
|
102828
|
-
}
|
|
102829
102685
|
cacheNormalize(_context) {
|
|
102830
102686
|
return { kind: this.kind, reportType: this.reportType, path: this.path };
|
|
102831
102687
|
}
|
|
102832
|
-
cachePlaceholder(context) {
|
|
102833
|
-
return context.value;
|
|
102834
|
-
}
|
|
102835
102688
|
}
|
|
102836
102689
|
var report = {
|
|
102837
102690
|
junit: (path) => new ReportOperation("junit", path),
|
|
102838
102691
|
coverage: (path) => new ReportOperation("coverage", path)
|
|
102839
102692
|
};
|
|
102840
|
-
// ../
|
|
102841
|
-
class BindServiceOperation {
|
|
102693
|
+
// ../core/dist/ops/bind.js
|
|
102694
|
+
class BindServiceOperation extends OperationBase {
|
|
102842
102695
|
service;
|
|
102843
102696
|
alias;
|
|
102844
102697
|
constructor(service2, alias) {
|
|
102698
|
+
super();
|
|
102845
102699
|
this.service = service2;
|
|
102846
102700
|
if (alias)
|
|
102847
102701
|
this.alias = alias;
|
|
@@ -102855,30 +102709,15 @@ class BindServiceOperation {
|
|
|
102855
102709
|
op.alias = this.alias;
|
|
102856
102710
|
return op;
|
|
102857
102711
|
}
|
|
102858
|
-
analysisPlaceholder() {
|
|
102859
|
-
return;
|
|
102860
|
-
}
|
|
102861
|
-
extractDependencies(_taskName) {
|
|
102862
|
-
return [];
|
|
102863
|
-
}
|
|
102864
|
-
extractSecrets() {
|
|
102865
|
-
return [];
|
|
102866
|
-
}
|
|
102867
|
-
extractRefs() {
|
|
102868
|
-
return [];
|
|
102869
|
-
}
|
|
102870
102712
|
cacheNormalize(_context) {
|
|
102871
102713
|
return { kind: this.kind, service: this.service, alias: this.alias ?? null };
|
|
102872
102714
|
}
|
|
102873
|
-
cachePlaceholder(context) {
|
|
102874
|
-
return context.value;
|
|
102875
|
-
}
|
|
102876
102715
|
}
|
|
102877
102716
|
var bind = (serviceInstance, alias) => new BindServiceOperation(serviceInstance, alias);
|
|
102878
|
-
// ../
|
|
102717
|
+
// ../core/dist/engine/cache/coordinator.js
|
|
102879
102718
|
import { join as join4 } from "node:path";
|
|
102880
102719
|
|
|
102881
|
-
// ../
|
|
102720
|
+
// ../core/dist/engine/executor/file-system.js
|
|
102882
102721
|
var import_picomatch = __toESM(require_picomatch2(), 1);
|
|
102883
102722
|
import { mkdir, readFile as readFile3, readdir, stat, writeFile } from "node:fs/promises";
|
|
102884
102723
|
import { dirname, join, relative } from "node:path";
|
|
@@ -102926,7 +102765,7 @@ var writeFiles = async (basePath, files) => {
|
|
|
102926
102765
|
}));
|
|
102927
102766
|
};
|
|
102928
102767
|
|
|
102929
|
-
// ../
|
|
102768
|
+
// ../core/dist/engine/cache/serialize.js
|
|
102930
102769
|
var isPlainObject = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
102931
102770
|
var stableStringify = (value) => {
|
|
102932
102771
|
if (value === null || value === undefined)
|
|
@@ -102946,7 +102785,7 @@ var stableStringify = (value) => {
|
|
|
102946
102785
|
return JSON.stringify(String(value));
|
|
102947
102786
|
};
|
|
102948
102787
|
|
|
102949
|
-
// ../
|
|
102788
|
+
// ../core/dist/engine/cache/analyze.js
|
|
102950
102789
|
var createPlaceholderTracker = () => {
|
|
102951
102790
|
let touched = false;
|
|
102952
102791
|
const placeholder = new Proxy(() => {
|
|
@@ -103048,7 +102887,7 @@ var analyzeTaskSteps = (task2, workspace) => {
|
|
|
103048
102887
|
return primary.analysis;
|
|
103049
102888
|
};
|
|
103050
102889
|
|
|
103051
|
-
// ../
|
|
102890
|
+
// ../core/dist/engine/cache/hasher.js
|
|
103052
102891
|
import { createHash as createHash2 } from "node:crypto";
|
|
103053
102892
|
import { readFile as readFile4 } from "node:fs/promises";
|
|
103054
102893
|
import { join as join2, relative as relative2 } from "node:path";
|
|
@@ -103097,7 +102936,7 @@ var hashNamedValues = (values) => {
|
|
|
103097
102936
|
return toHex(overall);
|
|
103098
102937
|
};
|
|
103099
102938
|
|
|
103100
|
-
// ../
|
|
102939
|
+
// ../core/dist/engine/cache/inference.js
|
|
103101
102940
|
var trimCommand = (command) => command.replace(/\s+/g, " ").trim();
|
|
103102
102941
|
var inferInputsFromCommand = (command) => {
|
|
103103
102942
|
const normalized = trimCommand(command.toLowerCase());
|
|
@@ -103141,7 +102980,7 @@ var inferOutputsFromCommand = (command) => {
|
|
|
103141
102980
|
return [];
|
|
103142
102981
|
};
|
|
103143
102982
|
|
|
103144
|
-
// ../
|
|
102983
|
+
// ../core/dist/engine/cache/store.js
|
|
103145
102984
|
import { existsSync } from "node:fs";
|
|
103146
102985
|
import { mkdir as mkdir2, readFile as readFile5, readdir as readdir2, rm, stat as stat2, writeFile as writeFile2 } from "node:fs/promises";
|
|
103147
102986
|
import { join as join3 } from "node:path";
|
|
@@ -103347,7 +103186,7 @@ class CacheStore {
|
|
|
103347
103186
|
}
|
|
103348
103187
|
}
|
|
103349
103188
|
|
|
103350
|
-
// ../
|
|
103189
|
+
// ../core/dist/engine/cache/coordinator.js
|
|
103351
103190
|
class CacheCoordinator {
|
|
103352
103191
|
workspace;
|
|
103353
103192
|
settings;
|
|
@@ -104086,7 +103925,7 @@ class CacheCoordinator {
|
|
|
104086
103925
|
}
|
|
104087
103926
|
}
|
|
104088
103927
|
|
|
104089
|
-
// ../
|
|
103928
|
+
// ../core/dist/engine/handlers/annotate-handler.js
|
|
104090
103929
|
class AnnotateHandler {
|
|
104091
103930
|
kind = "annotate";
|
|
104092
103931
|
async execute(op, context, _state) {
|
|
@@ -104095,7 +103934,7 @@ class AnnotateHandler {
|
|
|
104095
103934
|
}
|
|
104096
103935
|
}
|
|
104097
103936
|
|
|
104098
|
-
// ../
|
|
103937
|
+
// ../core/dist/engine/handlers/artifact-download-handler.js
|
|
104099
103938
|
import { existsSync as existsSync2 } from "node:fs";
|
|
104100
103939
|
import { mkdir as mkdir3, readFile as readFile6 } from "node:fs/promises";
|
|
104101
103940
|
import { join as join5, relative as relative3 } from "node:path";
|
|
@@ -104131,7 +103970,7 @@ class ArtifactDownloadHandler {
|
|
|
104131
103970
|
}
|
|
104132
103971
|
}
|
|
104133
103972
|
|
|
104134
|
-
// ../
|
|
103973
|
+
// ../core/dist/engine/handlers/artifact-upload-handler.js
|
|
104135
103974
|
import { join as join6 } from "node:path";
|
|
104136
103975
|
class ArtifactUploadHandler {
|
|
104137
103976
|
kind = "artifact-upload";
|
|
@@ -104156,7 +103995,7 @@ class ArtifactUploadHandler {
|
|
|
104156
103995
|
}
|
|
104157
103996
|
}
|
|
104158
103997
|
|
|
104159
|
-
// ../
|
|
103998
|
+
// ../core/dist/engine/handlers/bind-service-handler.js
|
|
104160
103999
|
class BindServiceHandler {
|
|
104161
104000
|
kind = "bind-service";
|
|
104162
104001
|
async execute(op, context, _state) {
|
|
@@ -104165,7 +104004,7 @@ class BindServiceHandler {
|
|
|
104165
104004
|
}
|
|
104166
104005
|
}
|
|
104167
104006
|
|
|
104168
|
-
// ../
|
|
104007
|
+
// ../core/dist/engine/handlers/cache-mount-handler.js
|
|
104169
104008
|
import { existsSync as existsSync3 } from "node:fs";
|
|
104170
104009
|
import { mkdir as mkdir4 } from "node:fs/promises";
|
|
104171
104010
|
import { join as join7 } from "node:path";
|
|
@@ -104183,7 +104022,7 @@ class CacheMountHandler {
|
|
|
104183
104022
|
}
|
|
104184
104023
|
}
|
|
104185
104024
|
|
|
104186
|
-
// ../
|
|
104025
|
+
// ../core/dist/engine/handlers/command-handler.js
|
|
104187
104026
|
class CommandHandler {
|
|
104188
104027
|
runner;
|
|
104189
104028
|
kind = "command";
|
|
@@ -104195,7 +104034,7 @@ class CommandHandler {
|
|
|
104195
104034
|
}
|
|
104196
104035
|
}
|
|
104197
104036
|
|
|
104198
|
-
// ../
|
|
104037
|
+
// ../core/dist/engine/handlers/emit-handler.js
|
|
104199
104038
|
class EmitHandler {
|
|
104200
104039
|
kind = "emit";
|
|
104201
104040
|
async execute(op, _context, state) {
|
|
@@ -104204,7 +104043,7 @@ class EmitHandler {
|
|
|
104204
104043
|
}
|
|
104205
104044
|
}
|
|
104206
104045
|
|
|
104207
|
-
// ../
|
|
104046
|
+
// ../core/dist/engine/handlers/env-handler.js
|
|
104208
104047
|
class EnvHandler {
|
|
104209
104048
|
kind = "env";
|
|
104210
104049
|
async execute(op, context, _state) {
|
|
@@ -104214,7 +104053,7 @@ class EnvHandler {
|
|
|
104214
104053
|
}
|
|
104215
104054
|
}
|
|
104216
104055
|
|
|
104217
|
-
// ../
|
|
104056
|
+
// ../core/dist/engine/handlers/http-handler.js
|
|
104218
104057
|
import { readFile as readFile7 } from "node:fs/promises";
|
|
104219
104058
|
import { isAbsolute, resolve } from "node:path";
|
|
104220
104059
|
class HttpHandler {
|
|
@@ -104281,7 +104120,7 @@ class HttpHandler {
|
|
|
104281
104120
|
}
|
|
104282
104121
|
}
|
|
104283
104122
|
|
|
104284
|
-
// ../
|
|
104123
|
+
// ../core/dist/engine/handlers/pack-handler.js
|
|
104285
104124
|
class PackHandler {
|
|
104286
104125
|
kind = "pack";
|
|
104287
104126
|
async execute(op, context, state) {
|
|
@@ -104294,7 +104133,7 @@ class PackHandler {
|
|
|
104294
104133
|
}
|
|
104295
104134
|
}
|
|
104296
104135
|
|
|
104297
|
-
// ../
|
|
104136
|
+
// ../core/dist/engine/handlers/registry.js
|
|
104298
104137
|
class OpHandlerRegistry {
|
|
104299
104138
|
handlers = new Map;
|
|
104300
104139
|
register(handler) {
|
|
@@ -104309,7 +104148,7 @@ class OpHandlerRegistry {
|
|
|
104309
104148
|
}
|
|
104310
104149
|
}
|
|
104311
104150
|
|
|
104312
|
-
// ../
|
|
104151
|
+
// ../core/dist/engine/handlers/report-handler.js
|
|
104313
104152
|
class ReportHandler {
|
|
104314
104153
|
kind = "report";
|
|
104315
104154
|
async execute(op, context, _state) {
|
|
@@ -104323,7 +104162,7 @@ class ReportHandler {
|
|
|
104323
104162
|
}
|
|
104324
104163
|
}
|
|
104325
104164
|
|
|
104326
|
-
// ../
|
|
104165
|
+
// ../core/dist/engine/handlers/summary-handler.js
|
|
104327
104166
|
class SummaryHandler {
|
|
104328
104167
|
kind = "summary";
|
|
104329
104168
|
async execute(op, _context, state) {
|
|
@@ -104332,7 +104171,7 @@ class SummaryHandler {
|
|
|
104332
104171
|
}
|
|
104333
104172
|
}
|
|
104334
104173
|
|
|
104335
|
-
// ../
|
|
104174
|
+
// ../core/dist/engine/handlers/unpack-handler.js
|
|
104336
104175
|
class UnpackHandler {
|
|
104337
104176
|
executeTask;
|
|
104338
104177
|
states;
|
|
@@ -104355,7 +104194,7 @@ class UnpackHandler {
|
|
|
104355
104194
|
}
|
|
104356
104195
|
}
|
|
104357
104196
|
|
|
104358
|
-
// ../
|
|
104197
|
+
// ../core/dist/engine/handlers/use-handler.js
|
|
104359
104198
|
class UseHandler {
|
|
104360
104199
|
executeTask;
|
|
104361
104200
|
states;
|
|
@@ -104377,7 +104216,7 @@ class UseHandler {
|
|
|
104377
104216
|
}
|
|
104378
104217
|
}
|
|
104379
104218
|
|
|
104380
|
-
// ../
|
|
104219
|
+
// ../core/dist/engine/executor/command-runner.js
|
|
104381
104220
|
import { spawn } from "node:child_process";
|
|
104382
104221
|
class CommandRunner {
|
|
104383
104222
|
workspace;
|
|
@@ -104511,7 +104350,7 @@ class CommandRunner {
|
|
|
104511
104350
|
}
|
|
104512
104351
|
}
|
|
104513
104352
|
|
|
104514
|
-
// ../
|
|
104353
|
+
// ../core/dist/engine/executor/value-resolver.js
|
|
104515
104354
|
class ValueResolver {
|
|
104516
104355
|
states;
|
|
104517
104356
|
params;
|
|
@@ -104574,7 +104413,7 @@ class ValueResolver {
|
|
|
104574
104413
|
}
|
|
104575
104414
|
}
|
|
104576
104415
|
|
|
104577
|
-
// ../
|
|
104416
|
+
// ../core/dist/engine/executor/plan-runner.js
|
|
104578
104417
|
var mergeEnv = (...sources) => {
|
|
104579
104418
|
const merged = {};
|
|
104580
104419
|
for (const source of sources) {
|
|
@@ -104972,7 +104811,7 @@ class PlanRunner {
|
|
|
104972
104811
|
}
|
|
104973
104812
|
}
|
|
104974
104813
|
|
|
104975
|
-
// ../
|
|
104814
|
+
// ../core/dist/engine/executor/executor.js
|
|
104976
104815
|
var defaultLogger = {
|
|
104977
104816
|
info: (message) => console.log(message),
|
|
104978
104817
|
error: (message) => console.error(message),
|
|
@@ -105190,15 +105029,15 @@ Available plans: ${available}`);
|
|
|
105190
105029
|
async function run() {
|
|
105191
105030
|
const startTime = Date.now();
|
|
105192
105031
|
try {
|
|
105193
|
-
const plan2 =
|
|
105194
|
-
const file =
|
|
105195
|
-
const task2 =
|
|
105196
|
-
const timeout =
|
|
105197
|
-
const failFast =
|
|
105198
|
-
const workdirInput =
|
|
105032
|
+
const plan2 = core7.getInput("plan", { required: true });
|
|
105033
|
+
const file = core7.getInput("file") || ".kitsi/pipeline.ts";
|
|
105034
|
+
const task2 = core7.getInput("task") || undefined;
|
|
105035
|
+
const timeout = core7.getInput("timeout") || "30m";
|
|
105036
|
+
const failFast = core7.getBooleanInput("fail-fast");
|
|
105037
|
+
const workdirInput = core7.getInput("working-directory");
|
|
105199
105038
|
const defaultWorkdir = process.env.GITHUB_WORKSPACE || ".";
|
|
105200
105039
|
const workdir = !workdirInput || workdirInput === "." ? defaultWorkdir : workdirInput;
|
|
105201
|
-
|
|
105040
|
+
core7.info(`Running Kitsi plan: ${plan2}`);
|
|
105202
105041
|
const capabilities = new GitHubCapabilities;
|
|
105203
105042
|
const groups = new GroupManager;
|
|
105204
105043
|
const result = await runPipeline({
|
|
@@ -105217,16 +105056,16 @@ async function run() {
|
|
|
105217
105056
|
});
|
|
105218
105057
|
const duration = (Date.now() - startTime) / 1000;
|
|
105219
105058
|
const status = Object.values(result.tasks).some((t) => t.status === "failed") ? "failed" : "success";
|
|
105220
|
-
|
|
105221
|
-
|
|
105222
|
-
|
|
105059
|
+
core7.setOutput("status", status);
|
|
105060
|
+
core7.setOutput("duration", duration.toFixed(1));
|
|
105061
|
+
core7.setOutput("tasks", JSON.stringify(result.tasks));
|
|
105223
105062
|
await capabilities.summary.writePlanSummary(plan2, result, duration);
|
|
105224
105063
|
if (status === "failed") {
|
|
105225
105064
|
for (const [name, taskResult] of Object.entries(result.tasks)) {
|
|
105226
105065
|
if (taskResult.status !== "failed")
|
|
105227
105066
|
continue;
|
|
105228
105067
|
if (taskResult.error) {
|
|
105229
|
-
|
|
105068
|
+
core7.error(`Task "${name}" failed: ${taskResult.error.message}`);
|
|
105230
105069
|
const cause = taskResult.error.cause;
|
|
105231
105070
|
if (cause) {
|
|
105232
105071
|
const formatted = typeof cause === "string" ? cause : cause instanceof Error ? cause.message : (() => {
|
|
@@ -105239,23 +105078,23 @@ async function run() {
|
|
|
105239
105078
|
for (const line of formatted.split(`
|
|
105240
105079
|
`)) {
|
|
105241
105080
|
if (line.trim().length > 0) {
|
|
105242
|
-
|
|
105081
|
+
core7.error(line);
|
|
105243
105082
|
}
|
|
105244
105083
|
}
|
|
105245
105084
|
}
|
|
105246
105085
|
} else {
|
|
105247
|
-
|
|
105086
|
+
core7.error(`Task "${name}" failed`);
|
|
105248
105087
|
}
|
|
105249
105088
|
}
|
|
105250
105089
|
}
|
|
105251
105090
|
if (status === "success") {
|
|
105252
|
-
|
|
105091
|
+
core7.info(`Plan "${plan2}" completed successfully in ${duration.toFixed(1)}s`);
|
|
105253
105092
|
} else {
|
|
105254
|
-
|
|
105093
|
+
core7.setFailed(`Plan "${plan2}" failed`);
|
|
105255
105094
|
}
|
|
105256
105095
|
} catch (error3) {
|
|
105257
105096
|
const message = error3 instanceof Error ? error3.message : String(error3);
|
|
105258
|
-
|
|
105097
|
+
core7.setFailed(message);
|
|
105259
105098
|
}
|
|
105260
105099
|
}
|
|
105261
105100
|
run();
|