buildkite-graph
Advanced tools
Comparing version
@@ -6,3 +6,3 @@ "use strict"; | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; | ||
return extendStatics(d, b); | ||
@@ -87,2 +87,3 @@ }; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.mapToObject = exports.exitStatusPredicate = exports.Chainable = exports.LabeledStep = exports.BranchLimitedStep = exports.Step = void 0; | ||
var ow_1 = __importDefault(require("ow")); | ||
@@ -115,3 +116,3 @@ var lodash_sortby_1 = __importDefault(require("lodash.sortby")); | ||
}, | ||
enumerable: true, | ||
enumerable: false, | ||
configurable: true | ||
@@ -205,4 +206,3 @@ }); | ||
: _this.always || undefined, | ||
}); }), | ||
'step']); | ||
}); }), 'step']); | ||
/* eslint-disable @typescript-eslint/camelcase */ | ||
@@ -261,3 +261,3 @@ return [2 /*return*/, { | ||
}, | ||
enumerable: true, | ||
enumerable: false, | ||
configurable: true | ||
@@ -264,0 +264,0 @@ }); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.Conditional = void 0; | ||
var Conditional = /** @class */ (function () { | ||
@@ -4,0 +5,0 @@ function Conditional(guarded) { |
@@ -53,2 +53,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.Pipeline = exports.serializers = exports.TriggerStep = exports.Plugin = exports.CommandStep = exports.Command = exports.TextField = exports.SelectField = exports.Option = exports.BlockStep = exports.Conditional = exports.Step = void 0; | ||
var slugify_1 = __importDefault(require("@sindresorhus/slugify")); | ||
@@ -64,18 +65,18 @@ var key_value_1 = require("./key_value"); | ||
var base_1 = require("./base"); | ||
exports.Step = base_1.Step; | ||
Object.defineProperty(exports, "Step", { enumerable: true, get: function () { return base_1.Step; } }); | ||
var conditional_1 = require("./conditional"); | ||
exports.Conditional = conditional_1.Conditional; | ||
Object.defineProperty(exports, "Conditional", { enumerable: true, get: function () { return conditional_1.Conditional; } }); | ||
var block_1 = require("./steps/block"); | ||
exports.BlockStep = block_1.BlockStep; | ||
Object.defineProperty(exports, "BlockStep", { enumerable: true, get: function () { return block_1.BlockStep; } }); | ||
var fields_1 = require("./steps/block/fields"); | ||
exports.Option = fields_1.Option; | ||
exports.SelectField = fields_1.SelectField; | ||
exports.TextField = fields_1.TextField; | ||
Object.defineProperty(exports, "Option", { enumerable: true, get: function () { return fields_1.Option; } }); | ||
Object.defineProperty(exports, "SelectField", { enumerable: true, get: function () { return fields_1.SelectField; } }); | ||
Object.defineProperty(exports, "TextField", { enumerable: true, get: function () { return fields_1.TextField; } }); | ||
var command_1 = require("./steps/command"); | ||
exports.Command = command_1.Command; | ||
exports.CommandStep = command_1.CommandStep; | ||
Object.defineProperty(exports, "Command", { enumerable: true, get: function () { return command_1.Command; } }); | ||
Object.defineProperty(exports, "CommandStep", { enumerable: true, get: function () { return command_1.CommandStep; } }); | ||
var plugins_1 = require("./steps/command/plugins"); | ||
exports.Plugin = plugins_1.Plugin; | ||
Object.defineProperty(exports, "Plugin", { enumerable: true, get: function () { return plugins_1.Plugin; } }); | ||
var trigger_1 = require("./steps/trigger"); | ||
exports.TriggerStep = trigger_1.TriggerStep; | ||
Object.defineProperty(exports, "TriggerStep", { enumerable: true, get: function () { return trigger_1.TriggerStep; } }); | ||
exports.serializers = { | ||
@@ -168,3 +169,4 @@ DotSerializer: dot_1.DotSerializer, | ||
return __awaiter(this, void 0, void 0, function () { | ||
var newOpts, _a, _b, _c; | ||
var newOpts, _a, _b; | ||
var _c; | ||
return __generator(this, function (_d) { | ||
@@ -181,11 +183,11 @@ switch (_d.label) { | ||
}; | ||
_a = {}; | ||
_c = {}; | ||
return [4 /*yield*/, this.env.toJson()]; | ||
case 1: | ||
_a.env = _d.sent(); | ||
_c = (_b = Promise).all; | ||
_c.env = _d.sent(); | ||
_b = (_a = Promise).all; | ||
return [4 /*yield*/, this.toList(newOpts)]; | ||
case 2: return [4 /*yield*/, _c.apply(_b, [(_d.sent()).map(function (s) { return s.toJson(newOpts); })])]; | ||
case 3: return [2 /*return*/, (_a.steps = _d.sent(), | ||
_a)]; | ||
case 2: return [4 /*yield*/, _b.apply(_a, [(_d.sent()).map(function (s) { return s.toJson(newOpts); })])]; | ||
case 3: return [2 /*return*/, (_c.steps = _d.sent(), | ||
_c)]; | ||
} | ||
@@ -192,0 +194,0 @@ }); |
@@ -6,3 +6,3 @@ "use strict"; | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; | ||
return extendStatics(d, b); | ||
@@ -56,2 +56,3 @@ }; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.KeyValueImpl = void 0; | ||
var ow_1 = __importDefault(require("ow")); | ||
@@ -58,0 +59,0 @@ var base_1 = require("./base"); |
"use strict"; | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); | ||
}) : (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
o[k2] = m[k]; | ||
})); | ||
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { | ||
Object.defineProperty(o, "default", { enumerable: true, value: v }); | ||
}) : function(o, v) { | ||
o["default"] = v; | ||
}); | ||
var __importStar = (this && this.__importStar) || function (mod) { | ||
if (mod && mod.__esModule) return mod; | ||
var result = {}; | ||
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); | ||
__setModuleDefault(result, mod); | ||
return result; | ||
}; | ||
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
@@ -49,10 +68,4 @@ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } | ||
}; | ||
var __importStar = (this && this.__importStar) || function (mod) { | ||
if (mod && mod.__esModule) return mod; | ||
var result = {}; | ||
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k]; | ||
result["default"] = mod; | ||
return result; | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.DotSerializer = void 0; | ||
var graphviz = __importStar(require("graphviz")); | ||
@@ -59,0 +72,0 @@ var __1 = require("../"); |
@@ -39,2 +39,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.JsonSerializer = void 0; | ||
var JsonSerializer = /** @class */ (function () { | ||
@@ -41,0 +42,0 @@ function JsonSerializer(opts) { |
@@ -39,2 +39,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.StructuralSerializer = void 0; | ||
var StructuralSerializer = /** @class */ (function () { | ||
@@ -41,0 +42,0 @@ function StructuralSerializer() { |
@@ -13,2 +13,21 @@ "use strict"; | ||
}; | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); | ||
}) : (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
o[k2] = m[k]; | ||
})); | ||
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { | ||
Object.defineProperty(o, "default", { enumerable: true, value: v }); | ||
}) : function(o, v) { | ||
o["default"] = v; | ||
}); | ||
var __importStar = (this && this.__importStar) || function (mod) { | ||
if (mod && mod.__esModule) return mod; | ||
var result = {}; | ||
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); | ||
__setModuleDefault(result, mod); | ||
return result; | ||
}; | ||
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
@@ -50,10 +69,4 @@ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } | ||
}; | ||
var __importStar = (this && this.__importStar) || function (mod) { | ||
if (mod && mod.__esModule) return mod; | ||
var result = {}; | ||
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k]; | ||
result["default"] = mod; | ||
return result; | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.YamlSerializer = void 0; | ||
var jsyaml = __importStar(require("js-yaml")); | ||
@@ -60,0 +73,0 @@ var json_1 = require("./json"); |
@@ -73,2 +73,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.sortedSteps = void 0; | ||
var topological_sort_1 = __importDefault(require("topological-sort")); | ||
@@ -75,0 +76,0 @@ var unwrapSteps_1 = require("./unwrapSteps"); |
@@ -50,2 +50,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.sortedWithBlocks = void 0; | ||
var sortedSteps_1 = require("./sortedSteps"); | ||
@@ -52,0 +53,0 @@ var conditional_1 = require("./conditional"); |
@@ -6,3 +6,3 @@ "use strict"; | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; | ||
return extendStatics(d, b); | ||
@@ -67,2 +67,3 @@ }; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.BlockStep = void 0; | ||
var ow_1 = __importDefault(require("ow")); | ||
@@ -87,3 +88,4 @@ var base_1 = require("../base"); | ||
return __awaiter(this, void 0, void 0, function () { | ||
var _a, _b, _c; | ||
var _a, _b; | ||
var _c; | ||
return __generator(this, function (_d) { | ||
@@ -90,0 +92,0 @@ switch (_d.label) { |
@@ -6,3 +6,3 @@ "use strict"; | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; | ||
return extendStatics(d, b); | ||
@@ -87,2 +87,3 @@ }; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.FieldsImpl = exports.SelectField = exports.Option = exports.TextField = void 0; | ||
var ow_1 = __importDefault(require("ow")); | ||
@@ -175,3 +176,4 @@ var base_1 = require("../../base"); | ||
return __awaiter(this, void 0, void 0, function () { | ||
var _a, _b, _c; | ||
var _a, _b; | ||
var _c; | ||
return __generator(this, function (_d) { | ||
@@ -178,0 +180,0 @@ switch (_d.label) { |
@@ -6,3 +6,3 @@ "use strict"; | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; | ||
return extendStatics(d, b); | ||
@@ -98,2 +98,3 @@ }; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.CommandStep = exports.Command = void 0; | ||
var ow_1 = __importDefault(require("ow")); | ||
@@ -193,3 +194,3 @@ var key_value_1 = require("../key_value"); | ||
}, | ||
enumerable: true, | ||
enumerable: false, | ||
configurable: true | ||
@@ -203,3 +204,3 @@ }); | ||
}, | ||
enumerable: true, | ||
enumerable: false, | ||
configurable: true | ||
@@ -211,3 +212,3 @@ }); | ||
}, | ||
enumerable: true, | ||
enumerable: false, | ||
configurable: true | ||
@@ -236,3 +237,3 @@ }); | ||
}, | ||
enumerable: true, | ||
enumerable: false, | ||
configurable: true | ||
@@ -330,3 +331,4 @@ }); | ||
return __awaiter(this, void 0, void 0, function () { | ||
var _a, _b, _c; | ||
var _a, _b; | ||
var _c; | ||
return __generator(this, function (_d) { | ||
@@ -339,12 +341,9 @@ switch (_d.label) { | ||
_b = [__assign.apply(void 0, _a.concat([(_d.sent())]))]; | ||
_c = { command: transformCommand(this.command) }; | ||
return [4 /*yield*/, this.env.toJson()]; | ||
case 2: | ||
_c.env = _d.sent(), _c.parallelism = this.parallelism, _c.concurrency = this.concurrency, _c.concurrency_group = this.concurrencyGroup, _c.concurrency_method = this.concurrencyMethod, _c.artifact_paths = this._artifactPaths.size | ||
? Array.from(this._artifactPaths) | ||
: undefined, _c.agents = this.agents.size ? base_1.mapToObject(this.agents) : undefined, _c.timeout_in_minutes = this.timeout, _c.plugins = plugins_1.transformPlugins(this.plugins), _c.soft_fail = transformSoftFail(this._softFail), _c.skip = this._skip ? transformSkipValue(this._skip) : undefined; | ||
return [4 /*yield*/, this.retry.toJson()]; | ||
case 2: return [4 /*yield*/, this.retry.toJson()]; | ||
case 3: | ||
/* eslint-disable @typescript-eslint/camelcase */ | ||
return [2 /*return*/, __assign.apply(void 0, _b.concat([(_c.retry = _d.sent(), _c)]))]; | ||
return [2 /*return*/, __assign.apply(void 0, _b.concat([(_c = { command: transformCommand(this.command) }, _c.env = _d.sent(), _c.parallelism = this.parallelism, _c.concurrency = this.concurrency, _c.concurrency_group = this.concurrencyGroup, _c.concurrency_method = this.concurrencyMethod, _c.artifact_paths = this._artifactPaths.size | ||
? Array.from(this._artifactPaths) | ||
: undefined, _c.agents = this.agents.size ? base_1.mapToObject(this.agents) : undefined, _c.timeout_in_minutes = this.timeout, _c.plugins = plugins_1.transformPlugins(this.plugins), _c.soft_fail = transformSoftFail(this._softFail), _c.skip = this._skip ? transformSkipValue(this._skip) : undefined, _c.retry = _d.sent(), _c)]))]; | ||
} | ||
@@ -351,0 +350,0 @@ }); |
@@ -9,2 +9,4 @@ import { Chainable } from '../../base'; | ||
add(plugin: Plugin): T; | ||
/** Return a list of plugins that match the given predicate */ | ||
filter: Plugin[]['filter']; | ||
} | ||
@@ -15,2 +17,3 @@ export declare function transformPlugins(value: PluginsImpl<any>): object | undefined; | ||
add(plugin: Plugin): T; | ||
filter(...args: Parameters<Plugins<T>['filter']>): ReturnType<Plugins<T>['filter']>; | ||
} |
@@ -6,3 +6,3 @@ "use strict"; | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; | ||
return extendStatics(d, b); | ||
@@ -16,2 +16,22 @@ }; | ||
})(); | ||
var __read = (this && this.__read) || function (o, n) { | ||
var m = typeof Symbol === "function" && o[Symbol.iterator]; | ||
if (!m) return o; | ||
var i = m.call(o), r, ar = [], e; | ||
try { | ||
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value); | ||
} | ||
catch (error) { e = { error: error }; } | ||
finally { | ||
try { | ||
if (r && !r.done && (m = i["return"])) m.call(i); | ||
} | ||
finally { if (e) throw e.error; } | ||
} | ||
return ar; | ||
}; | ||
var __spread = (this && this.__spread) || function () { | ||
for (var ar = [], i = 0; i < arguments.length; i++) ar = ar.concat(__read(arguments[i])); | ||
return ar; | ||
}; | ||
var __importDefault = (this && this.__importDefault) || function (mod) { | ||
@@ -21,2 +41,3 @@ return (mod && mod.__esModule) ? mod : { "default": mod }; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.PluginsImpl = exports.transformPlugins = exports.Plugin = void 0; | ||
var ow_1 = __importDefault(require("ow")); | ||
@@ -56,4 +77,12 @@ var base_1 = require("../../base"); | ||
}; | ||
PluginsImpl.prototype.filter = function () { | ||
var _a; | ||
var args = []; | ||
for (var _i = 0; _i < arguments.length; _i++) { | ||
args[_i] = arguments[_i]; | ||
} | ||
return (_a = this.plugins).filter.apply(_a, __spread(args)); | ||
}; | ||
return PluginsImpl; | ||
}(base_1.Chainable)); | ||
exports.PluginsImpl = PluginsImpl; |
@@ -6,3 +6,3 @@ "use strict"; | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; | ||
return extendStatics(d, b); | ||
@@ -87,2 +87,3 @@ }; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.RetryImpl = void 0; | ||
var ow_1 = __importDefault(require("ow")); | ||
@@ -89,0 +90,0 @@ var base_1 = require("../../base"); |
@@ -6,3 +6,3 @@ "use strict"; | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; | ||
return extendStatics(d, b); | ||
@@ -64,2 +64,3 @@ }; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.TriggerStep = void 0; | ||
var index_1 = require("../index"); | ||
@@ -88,3 +89,3 @@ var base_1 = require("../base"); | ||
}, | ||
enumerable: true, | ||
enumerable: false, | ||
configurable: true | ||
@@ -102,3 +103,4 @@ }); | ||
return __awaiter(this, void 0, void 0, function () { | ||
var _a, _b, _c; | ||
var _a, _b; | ||
var _c; | ||
return __generator(this, function (_d) { | ||
@@ -105,0 +107,0 @@ switch (_d.label) { |
@@ -39,2 +39,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.BuildImpl = void 0; | ||
var key_value_1 = require("../../key_value"); | ||
@@ -41,0 +42,0 @@ var BuildImpl = /** @class */ (function () { |
@@ -39,2 +39,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.WaitStep = void 0; | ||
var WaitStep = /** @class */ (function () { | ||
@@ -41,0 +42,0 @@ function WaitStep(continueOnFailure) { |
@@ -50,2 +50,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.unwrapSteps = void 0; | ||
var conditional_1 = require("./conditional"); | ||
@@ -52,0 +53,0 @@ function unwrapSteps(steps, cache) { |
{ | ||
"name": "buildkite-graph", | ||
"version": "5.2.0", | ||
"version": "5.3.4", | ||
"main": "dist/index.js", | ||
@@ -29,3 +29,3 @@ "typings": "dist/index.d.ts", | ||
"rimraf": "^3.0.0", | ||
"semantic-release": "^15.13.31", | ||
"semantic-release": "^17.1.2", | ||
"ts-jest": "^24.2.0", | ||
@@ -65,4 +65,4 @@ "ts-node": "^8.5.4", | ||
"type": "git", | ||
"url": "https://github.com/joscha/buildkite-graph.git" | ||
"url": "git@github.com:joscha/buildkite-graph.git" | ||
} | ||
} |
157567
4.47%47
9.3%3150
4.44%