@trigger.dev/build 0.0.0-prerelease-20240905123715 → 0.0.0-prerelease-20240916123114
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/commonjs/extensions/core/aptGet.d.ts +5 -0
- package/dist/commonjs/extensions/core/aptGet.js +23 -0
- package/dist/commonjs/extensions/core/aptGet.js.map +1 -0
- package/dist/commonjs/extensions/core/ffmpeg.d.ts +11 -0
- package/dist/commonjs/extensions/core/ffmpeg.js +36 -0
- package/dist/commonjs/extensions/core/ffmpeg.js.map +1 -0
- package/dist/commonjs/extensions/core.d.ts +2 -0
- package/dist/commonjs/extensions/core.js +2 -0
- package/dist/commonjs/extensions/core.js.map +1 -1
- package/dist/commonjs/extensions/index.d.ts +3 -1
- package/dist/commonjs/extensions/index.js +4 -15
- package/dist/commonjs/extensions/index.js.map +1 -1
- package/dist/commonjs/extensions/prisma.d.ts +4 -0
- package/dist/commonjs/extensions/prisma.js +24 -5
- package/dist/commonjs/extensions/prisma.js.map +1 -1
- package/dist/commonjs/extensions/typescript.d.ts +1 -4
- package/dist/commonjs/extensions/typescript.js +45 -31
- package/dist/commonjs/extensions/typescript.js.map +1 -1
- package/dist/commonjs/index.d.ts +1 -1
- package/dist/commonjs/index.js +16 -0
- package/dist/commonjs/index.js.map +1 -1
- package/dist/esm/extensions/core/aptGet.d.ts +5 -0
- package/dist/esm/extensions/core/aptGet.js +20 -0
- package/dist/esm/extensions/core/aptGet.js.map +1 -0
- package/dist/esm/extensions/core/ffmpeg.d.ts +11 -0
- package/dist/esm/extensions/core/ffmpeg.js +33 -0
- package/dist/esm/extensions/core/ffmpeg.js.map +1 -0
- package/dist/esm/extensions/core.d.ts +2 -0
- package/dist/esm/extensions/core.js +2 -0
- package/dist/esm/extensions/core.js.map +1 -1
- package/dist/esm/extensions/index.d.ts +3 -1
- package/dist/esm/extensions/index.js +1 -1
- package/dist/esm/extensions/index.js.map +1 -1
- package/dist/esm/extensions/prisma.d.ts +4 -0
- package/dist/esm/extensions/prisma.js +24 -5
- package/dist/esm/extensions/prisma.js.map +1 -1
- package/dist/esm/extensions/typescript.d.ts +1 -4
- package/dist/esm/extensions/typescript.js +45 -31
- package/dist/esm/extensions/typescript.js.map +1 -1
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +2 -1
- package/dist/esm/index.js.map +1 -1
- package/package.json +4 -3
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.aptGet = aptGet;
|
|
4
|
+
function aptGet(options) {
|
|
5
|
+
return {
|
|
6
|
+
name: "aptGet",
|
|
7
|
+
onBuildComplete(context) {
|
|
8
|
+
if (context.target === "dev") {
|
|
9
|
+
return;
|
|
10
|
+
}
|
|
11
|
+
context.logger.debug("Adding apt-get layer", {
|
|
12
|
+
pkgs: options.packages,
|
|
13
|
+
});
|
|
14
|
+
context.addLayer({
|
|
15
|
+
id: "apt-get",
|
|
16
|
+
image: {
|
|
17
|
+
pkgs: options.packages,
|
|
18
|
+
},
|
|
19
|
+
});
|
|
20
|
+
},
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=aptGet.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"aptGet.js","sourceRoot":"","sources":["../../../../src/extensions/core/aptGet.ts"],"names":[],"mappings":";;AAMA,wBAoBC;AApBD,SAAgB,MAAM,CAAC,OAAsB;IAC3C,OAAO;QACL,IAAI,EAAE,QAAQ;QACd,eAAe,CAAC,OAAO;YACrB,IAAI,OAAO,CAAC,MAAM,KAAK,KAAK,EAAE,CAAC;gBAC7B,OAAO;YACT,CAAC;YAED,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,sBAAsB,EAAE;gBAC3C,IAAI,EAAE,OAAO,CAAC,QAAQ;aACvB,CAAC,CAAC;YAEH,OAAO,CAAC,QAAQ,CAAC;gBACf,EAAE,EAAE,SAAS;gBACb,KAAK,EAAE;oBACL,IAAI,EAAE,OAAO,CAAC,QAAQ;iBACvB;aACF,CAAC,CAAC;QACL,CAAC;KACF,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { BuildExtension } from "@trigger.dev/core/v3/build";
|
|
2
|
+
export type FfmpegOptions = {
|
|
3
|
+
version?: string;
|
|
4
|
+
};
|
|
5
|
+
/**
|
|
6
|
+
* Add ffmpeg to the build, and automatically set the FFMPEG_PATH and FFPROBE_PATH environment variables.
|
|
7
|
+
* @param options.version The version of ffmpeg to install. If not provided, the latest version will be installed.
|
|
8
|
+
*
|
|
9
|
+
* @returns The build extension.
|
|
10
|
+
*/
|
|
11
|
+
export declare function ffmpeg(options?: FfmpegOptions): BuildExtension;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ffmpeg = ffmpeg;
|
|
4
|
+
/**
|
|
5
|
+
* Add ffmpeg to the build, and automatically set the FFMPEG_PATH and FFPROBE_PATH environment variables.
|
|
6
|
+
* @param options.version The version of ffmpeg to install. If not provided, the latest version will be installed.
|
|
7
|
+
*
|
|
8
|
+
* @returns The build extension.
|
|
9
|
+
*/
|
|
10
|
+
function ffmpeg(options = {}) {
|
|
11
|
+
return {
|
|
12
|
+
name: "ffmpeg",
|
|
13
|
+
onBuildComplete(context) {
|
|
14
|
+
if (context.target === "dev") {
|
|
15
|
+
return;
|
|
16
|
+
}
|
|
17
|
+
context.logger.debug("Adding ffmpeg", {
|
|
18
|
+
options,
|
|
19
|
+
});
|
|
20
|
+
context.addLayer({
|
|
21
|
+
id: "ffmpeg",
|
|
22
|
+
image: {
|
|
23
|
+
pkgs: options.version ? [`ffmpeg=${options.version}`] : ["ffmpeg"],
|
|
24
|
+
},
|
|
25
|
+
deploy: {
|
|
26
|
+
env: {
|
|
27
|
+
FFMPEG_PATH: "/usr/bin/ffmpeg",
|
|
28
|
+
FFPROBE_PATH: "/usr/bin/ffprobe",
|
|
29
|
+
},
|
|
30
|
+
override: true,
|
|
31
|
+
},
|
|
32
|
+
});
|
|
33
|
+
},
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
//# sourceMappingURL=ffmpeg.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ffmpeg.js","sourceRoot":"","sources":["../../../../src/extensions/core/ffmpeg.ts"],"names":[],"mappings":";;AAYA,wBA2BC;AAjCD;;;;;GAKG;AACH,SAAgB,MAAM,CAAC,UAAyB,EAAE;IAChD,OAAO;QACL,IAAI,EAAE,QAAQ;QACd,eAAe,CAAC,OAAO;YACrB,IAAI,OAAO,CAAC,MAAM,KAAK,KAAK,EAAE,CAAC;gBAC7B,OAAO;YACT,CAAC;YAED,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,eAAe,EAAE;gBACpC,OAAO;aACR,CAAC,CAAC;YAEH,OAAO,CAAC,QAAQ,CAAC;gBACf,EAAE,EAAE,QAAQ;gBACZ,KAAK,EAAE;oBACL,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,UAAU,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC;iBACnE;gBACD,MAAM,EAAE;oBACN,GAAG,EAAE;wBACH,WAAW,EAAE,iBAAiB;wBAC9B,YAAY,EAAE,kBAAkB;qBACjC;oBACD,QAAQ,EAAE,IAAI;iBACf;aACF,CAAC,CAAC;QACL,CAAC;KACF,CAAC;AACJ,CAAC"}
|
|
@@ -17,4 +17,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
17
17
|
__exportStar(require("./core/additionalFiles.js"), exports);
|
|
18
18
|
__exportStar(require("./core/additionalPackages.js"), exports);
|
|
19
19
|
__exportStar(require("./core/syncEnvVars.js"), exports);
|
|
20
|
+
__exportStar(require("./core/aptGet.js"), exports);
|
|
21
|
+
__exportStar(require("./core/ffmpeg.js"), exports);
|
|
20
22
|
//# sourceMappingURL=core.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core.js","sourceRoot":"","sources":["../../../src/extensions/core.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4DAA0C;AAC1C,+DAA6C;AAC7C,wDAAsC"}
|
|
1
|
+
{"version":3,"file":"core.js","sourceRoot":"","sources":["../../../src/extensions/core.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4DAA0C;AAC1C,+DAA6C;AAC7C,wDAAsC;AACtC,mDAAiC;AACjC,mDAAiC"}
|
|
@@ -1 +1,3 @@
|
|
|
1
|
-
export
|
|
1
|
+
export type { BuildContext, BuildExtension, BuildLayer, BuildLogger, BuildSpinner, RegisteredPlugin, RegisterPluginOptions, PluginPlacement, ResolvedConfig, } from "@trigger.dev/core/v3/build";
|
|
2
|
+
export type { BuildManifest, WorkerManifest } from "@trigger.dev/core/v3/schemas";
|
|
3
|
+
export { binaryForRuntime, esbuildPlugin } from "@trigger.dev/core/v3/build";
|
|
@@ -1,18 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
|
|
3
|
+
exports.esbuildPlugin = exports.binaryForRuntime = void 0;
|
|
4
|
+
var build_1 = require("@trigger.dev/core/v3/build");
|
|
5
|
+
Object.defineProperty(exports, "binaryForRuntime", { enumerable: true, get: function () { return build_1.binaryForRuntime; } });
|
|
6
|
+
Object.defineProperty(exports, "esbuildPlugin", { enumerable: true, get: function () { return build_1.esbuildPlugin; } });
|
|
18
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/extensions/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/extensions/index.ts"],"names":[],"mappings":";;;AAeA,oDAA6E;AAApE,yGAAA,gBAAgB,OAAA;AAAE,sGAAA,aAAa,OAAA"}
|
|
@@ -4,6 +4,10 @@ export type PrismaExtensionOptions = {
|
|
|
4
4
|
schema: string;
|
|
5
5
|
migrate?: boolean;
|
|
6
6
|
version?: string;
|
|
7
|
+
/**
|
|
8
|
+
* Adds the `--sql` flag to the `prisma generate` command. This will generate the SQL files for the Prisma schema. Requires the `typedSql preview feature and prisma 5.19.0 or later.
|
|
9
|
+
*/
|
|
10
|
+
typedSql?: boolean;
|
|
7
11
|
/**
|
|
8
12
|
* The client generator to use. Set this param to prevent all generators in the prisma schema from being generated.
|
|
9
13
|
*
|
|
@@ -58,9 +58,28 @@ class PrismaExtension {
|
|
|
58
58
|
const usingSchemaFolder = (0, node_path_1.dirname)(this._resolvedSchemaPath).endsWith("schema");
|
|
59
59
|
const commands = [];
|
|
60
60
|
let prismaDir;
|
|
61
|
-
const
|
|
62
|
-
|
|
63
|
-
|
|
61
|
+
const generatorFlags = [];
|
|
62
|
+
if (this.options.clientGenerator) {
|
|
63
|
+
generatorFlags.push(`--generator=${this.options.clientGenerator}`);
|
|
64
|
+
}
|
|
65
|
+
if (this.options.typedSql) {
|
|
66
|
+
generatorFlags.push(`--sql`);
|
|
67
|
+
const schemaDir = (0, node_path_1.dirname)(this._resolvedSchemaPath);
|
|
68
|
+
const prismaDir = (0, node_path_1.dirname)(schemaDir);
|
|
69
|
+
context.logger.debug(`Using typedSql`);
|
|
70
|
+
// Find all the files prisma/sql/*.sql
|
|
71
|
+
const sqlFiles = await (0, promises_1.readdir)((0, node_path_1.join)(prismaDir, "sql")).then((files) => files.filter((file) => file.endsWith(".sql")));
|
|
72
|
+
context.logger.debug(`Found sql files`, {
|
|
73
|
+
sqlFiles,
|
|
74
|
+
});
|
|
75
|
+
const sqlDestinationPath = (0, node_path_1.join)(manifest.outputPath, "prisma", "sql");
|
|
76
|
+
for (const file of sqlFiles) {
|
|
77
|
+
const destination = (0, node_path_1.join)(sqlDestinationPath, file);
|
|
78
|
+
const source = (0, node_path_1.join)(prismaDir, "sql", file);
|
|
79
|
+
context.logger.debug(`Copying the sql from ${source} to ${destination}`);
|
|
80
|
+
await (0, promises_1.cp)(source, destination);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
64
83
|
if (usingSchemaFolder) {
|
|
65
84
|
const schemaDir = (0, node_path_1.dirname)(this._resolvedSchemaPath);
|
|
66
85
|
prismaDir = (0, node_path_1.dirname)(schemaDir);
|
|
@@ -78,7 +97,7 @@ class PrismaExtension {
|
|
|
78
97
|
context.logger.debug(`Copying the prisma schema from ${source} to ${destination}`);
|
|
79
98
|
await (0, promises_1.cp)(source, destination);
|
|
80
99
|
}
|
|
81
|
-
commands.push(`${(0, build_1.binaryForRuntime)(manifest.runtime)} node_modules/prisma/build/index.js generate ${
|
|
100
|
+
commands.push(`${(0, build_1.binaryForRuntime)(manifest.runtime)} node_modules/prisma/build/index.js generate ${generatorFlags.join(" ")}` // Don't add the --schema flag or this will fail
|
|
82
101
|
);
|
|
83
102
|
}
|
|
84
103
|
else {
|
|
@@ -91,7 +110,7 @@ class PrismaExtension {
|
|
|
91
110
|
// Copy the prisma schema to the build output path
|
|
92
111
|
context.logger.debug(`Copying the prisma schema from ${this._resolvedSchemaPath} to ${schemaDestinationPath}`);
|
|
93
112
|
await (0, promises_1.cp)(this._resolvedSchemaPath, schemaDestinationPath);
|
|
94
|
-
commands.push(`${(0, build_1.binaryForRuntime)(manifest.runtime)} node_modules/prisma/build/index.js generate --schema=./prisma/schema.prisma ${
|
|
113
|
+
commands.push(`${(0, build_1.binaryForRuntime)(manifest.runtime)} node_modules/prisma/build/index.js generate --schema=./prisma/schema.prisma ${generatorFlags.join(" ")}`);
|
|
95
114
|
}
|
|
96
115
|
const env = {};
|
|
97
116
|
if (this.options.migrate) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prisma.js","sourceRoot":"","sources":["../../../src/extensions/prisma.ts"],"names":[],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"prisma.js","sourceRoot":"","sources":["../../../src/extensions/prisma.ts"],"names":[],"mappings":";;;;;;AAgDA,0CAEC;AAjDD,sDAA4F;AAC5F,8DAAiC;AACjC,qCAAqC;AACrC,+CAA+C;AAC/C,yCAAmD;AAyCnD,MAAM,aAAa,GAAG,2BAA2B,CAAC;AAElD,SAAgB,eAAe,CAAC,OAA+B;IAC7D,OAAO,IAAI,eAAe,CAAC,OAAO,CAAC,CAAC;AACtC,CAAC;AAED,MAAa,eAAe;IAON;IANpB,eAAe,CAAW;IAEV,IAAI,GAAG,iBAAiB,CAAC;IAEjC,mBAAmB,CAAU;IAErC,YAAoB,OAA+B;QAA/B,YAAO,GAAP,OAAO,CAAwB;QACjD,IAAI,CAAC,eAAe,GAAG,CAAC,gBAAgB,EAAE,iBAAiB,CAAC,CAAC;IAC/D,CAAC;IAED,kBAAkB,CAAC,MAAmB;QACpC,IAAI,MAAM,KAAK,KAAK,EAAE,CAAC;YACrB,OAAO,EAAE,CAAC;QACZ,CAAC;QAED,OAAO,IAAI,CAAC,eAAe,CAAC;IAC9B,CAA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ratorMetadata(options?: EmitDecoratorMetadataOptions): BuildExtension;
|
|
2
|
+
export declare function emitDecoratorMetadata(): BuildExtension;
|
|
@@ -4,43 +4,57 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.emitDecoratorMetadata = emitDecoratorMetadata;
|
|
7
|
-
const build_1 = require("@trigger.dev/core/v3/build");
|
|
8
7
|
const promises_1 = require("node:fs/promises");
|
|
9
|
-
const pkg_types_1 = require("pkg-types");
|
|
10
8
|
const typescript_1 = __importDefault(require("typescript"));
|
|
11
9
|
const { transpileModule, ModuleKind } = typescript_1.default;
|
|
12
10
|
const decoratorMatcher = new RegExp(/((?<![(\s]\s*['"])@\w[.[\]\w\d]*\s*(?![;])[((?=\s)])/);
|
|
13
|
-
function emitDecoratorMetadata(
|
|
14
|
-
return (0, build_1.esbuildPlugin)(plugin(options));
|
|
15
|
-
}
|
|
16
|
-
function plugin(options = {}) {
|
|
11
|
+
function emitDecoratorMetadata() {
|
|
17
12
|
return {
|
|
18
13
|
name: "emitDecoratorMetadata",
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
14
|
+
onBuildStart(context) {
|
|
15
|
+
context.registerPlugin({
|
|
16
|
+
name: "emitDecoratorMetadata",
|
|
17
|
+
async setup(build) {
|
|
18
|
+
const { parseNative, TSConfckCache } = await import("tsconfck");
|
|
19
|
+
const cache = new TSConfckCache();
|
|
20
|
+
build.onLoad({ filter: /\.ts$/ }, async (args) => {
|
|
21
|
+
context.logger.debug("emitDecoratorMetadata onLoad", { args });
|
|
22
|
+
const { tsconfigFile, tsconfig } = await parseNative(args.path, {
|
|
23
|
+
ignoreNodeModules: true,
|
|
24
|
+
cache,
|
|
25
|
+
});
|
|
26
|
+
context.logger.debug("emitDecoratorMetadata parsed native tsconfig", {
|
|
27
|
+
tsconfig,
|
|
28
|
+
tsconfigFile,
|
|
29
|
+
args,
|
|
30
|
+
});
|
|
31
|
+
if (tsconfig.compilerOptions?.emitDecoratorMetadata !== true) {
|
|
32
|
+
context.logger.debug("emitDecoratorMetadata skipping", {
|
|
33
|
+
args,
|
|
34
|
+
tsconfig,
|
|
35
|
+
});
|
|
36
|
+
return undefined;
|
|
37
|
+
}
|
|
38
|
+
const ts = await (0, promises_1.readFile)(args.path, "utf8");
|
|
39
|
+
if (!ts)
|
|
40
|
+
return undefined;
|
|
41
|
+
// Find the decorator and if there isn't one, return out
|
|
42
|
+
if (!decoratorMatcher.test(ts)) {
|
|
43
|
+
context.logger.debug("emitDecoratorMetadata skipping, no decorators found", {
|
|
44
|
+
args,
|
|
45
|
+
});
|
|
46
|
+
return undefined;
|
|
47
|
+
}
|
|
48
|
+
const program = transpileModule(ts, {
|
|
49
|
+
fileName: args.path,
|
|
50
|
+
compilerOptions: {
|
|
51
|
+
...tsconfig.compilerOptions,
|
|
52
|
+
module: ModuleKind.ES2022,
|
|
53
|
+
},
|
|
54
|
+
});
|
|
55
|
+
return { contents: program.outputText };
|
|
56
|
+
});
|
|
57
|
+
},
|
|
44
58
|
});
|
|
45
59
|
},
|
|
46
60
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typescript.js","sourceRoot":"","sources":["../../../src/extensions/typescript.ts"],"names":[],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"typescript.js","sourceRoot":"","sources":["../../../src/extensions/typescript.ts"],"names":[],"mappings":";;;;;AAQA,sDA4DC;AAnED,+CAA4C;AAC5C,4DAAuC;AAEvC,MAAM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AO,SAAS,CAAC;wBAE1B,wDAAwD;wBACxD,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,CAAC;4BAC/B,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,qDAAqD,EAAE;gCAC1E,IAAI;6BACL,CAAC,CAAC;4BAEH,OAAO,SAAS,CAAC;wBACnB,CAAC;wBAED,MAAM,OAAO,GAAG,eAAe,CAAC,EAAE,EAAE;4BAClC,QAAQ,EAAE,IAAI,CAAC,IAAI;4BACnB,eAAe,EAAE;gCACf,GAAG,QAAQ,CAAC,eAAe;gCAC3B,MAAM,EAAE,UAAU,CAAC,MAAM;6BAC1B;yBACF,CAAC,CAAC;wBAEH,OAAO,EAAE,QAAQ,EAAE,OAAO,CAAC,UAAU,EAAE,CAAC;oBAC1C,CAAC,CAAC,CAAC;gBACL,CAAC;aACF,CAAC,CAAC;QACL,CAAC;KACF,CAAC;AACJ,CAAC"}
|
package/dist/commonjs/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export
|
|
1
|
+
export * from "./extensions/index.js";
|
package/dist/commonjs/index.js
CHANGED
|
@@ -1,3 +1,19 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
2
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
// Barrel no more
|
|
18
|
+
__exportStar(require("./extensions/index.js"), exports);
|
|
3
19
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,iBAAiB;AACjB,wDAAsC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export function aptGet(options) {
|
|
2
|
+
return {
|
|
3
|
+
name: "aptGet",
|
|
4
|
+
onBuildComplete(context) {
|
|
5
|
+
if (context.target === "dev") {
|
|
6
|
+
return;
|
|
7
|
+
}
|
|
8
|
+
context.logger.debug("Adding apt-get layer", {
|
|
9
|
+
pkgs: options.packages,
|
|
10
|
+
});
|
|
11
|
+
context.addLayer({
|
|
12
|
+
id: "apt-get",
|
|
13
|
+
image: {
|
|
14
|
+
pkgs: options.packages,
|
|
15
|
+
},
|
|
16
|
+
});
|
|
17
|
+
},
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=aptGet.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"aptGet.js","sourceRoot":"","sources":["../../../../src/extensions/core/aptGet.ts"],"names":[],"mappings":"AAMA,MAAM,UAAU,MAAM,CAAC,OAAsB;IAC3C,OAAO;QACL,IAAI,EAAE,QAAQ;QACd,eAAe,CAAC,OAAO;YACrB,IAAI,OAAO,CAAC,MAAM,KAAK,KAAK,EAAE,CAAC;gBAC7B,OAAO;YACT,CAAC;YAED,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,sBAAsB,EAAE;gBAC3C,IAAI,EAAE,OAAO,CAAC,QAAQ;aACvB,CAAC,CAAC;YAEH,OAAO,CAAC,QAAQ,CAAC;gBACf,EAAE,EAAE,SAAS;gBACb,KAAK,EAAE;oBACL,IAAI,EAAE,OAAO,CAAC,QAAQ;iBACvB;aACF,CAAC,CAAC;QACL,CAAC;KACF,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { BuildExtension } from "@trigger.dev/core/v3/build";
|
|
2
|
+
export type FfmpegOptions = {
|
|
3
|
+
version?: string;
|
|
4
|
+
};
|
|
5
|
+
/**
|
|
6
|
+
* Add ffmpeg to the build, and automatically set the FFMPEG_PATH and FFPROBE_PATH environment variables.
|
|
7
|
+
* @param options.version The version of ffmpeg to install. If not provided, the latest version will be installed.
|
|
8
|
+
*
|
|
9
|
+
* @returns The build extension.
|
|
10
|
+
*/
|
|
11
|
+
export declare function ffmpeg(options?: FfmpegOptions): BuildExtension;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Add ffmpeg to the build, and automatically set the FFMPEG_PATH and FFPROBE_PATH environment variables.
|
|
3
|
+
* @param options.version The version of ffmpeg to install. If not provided, the latest version will be installed.
|
|
4
|
+
*
|
|
5
|
+
* @returns The build extension.
|
|
6
|
+
*/
|
|
7
|
+
export function ffmpeg(options = {}) {
|
|
8
|
+
return {
|
|
9
|
+
name: "ffmpeg",
|
|
10
|
+
onBuildComplete(context) {
|
|
11
|
+
if (context.target === "dev") {
|
|
12
|
+
return;
|
|
13
|
+
}
|
|
14
|
+
context.logger.debug("Adding ffmpeg", {
|
|
15
|
+
options,
|
|
16
|
+
});
|
|
17
|
+
context.addLayer({
|
|
18
|
+
id: "ffmpeg",
|
|
19
|
+
image: {
|
|
20
|
+
pkgs: options.version ? [`ffmpeg=${options.version}`] : ["ffmpeg"],
|
|
21
|
+
},
|
|
22
|
+
deploy: {
|
|
23
|
+
env: {
|
|
24
|
+
FFMPEG_PATH: "/usr/bin/ffmpeg",
|
|
25
|
+
FFPROBE_PATH: "/usr/bin/ffprobe",
|
|
26
|
+
},
|
|
27
|
+
override: true,
|
|
28
|
+
},
|
|
29
|
+
});
|
|
30
|
+
},
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
//# sourceMappingURL=ffmpeg.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ffmpeg.js","sourceRoot":"","sources":["../../../../src/extensions/core/ffmpeg.ts"],"names":[],"mappings":"AAMA;;;;;GAKG;AACH,MAAM,UAAU,MAAM,CAAC,UAAyB,EAAE;IAChD,OAAO;QACL,IAAI,EAAE,QAAQ;QACd,eAAe,CAAC,OAAO;YACrB,IAAI,OAAO,CAAC,MAAM,KAAK,KAAK,EAAE,CAAC;gBAC7B,OAAO;YACT,CAAC;YAED,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,eAAe,EAAE;gBACpC,OAAO;aACR,CAAC,CAAC;YAEH,OAAO,CAAC,QAAQ,CAAC;gBACf,EAAE,EAAE,QAAQ;gBACZ,KAAK,EAAE;oBACL,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,UAAU,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC;iBACnE;gBACD,MAAM,EAAE;oBACN,GAAG,EAAE;wBACH,WAAW,EAAE,iBAAiB;wBAC9B,YAAY,EAAE,kBAAkB;qBACjC;oBACD,QAAQ,EAAE,IAAI;iBACf;aACF,CAAC,CAAC;QACL,CAAC;KACF,CAAC;AACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"core.js","sourceRoot":"","sources":["../../../src/extensions/core.ts"],"names":[],"mappings":"AAAA,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,uBAAuB,CAAC"}
|
|
1
|
+
{"version":3,"file":"core.js","sourceRoot":"","sources":["../../../src/extensions/core.ts"],"names":[],"mappings":"AAAA,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,uBAAuB,CAAC;AACtC,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC"}
|
|
@@ -1 +1,3 @@
|
|
|
1
|
-
export
|
|
1
|
+
export type { BuildContext, BuildExtension, BuildLayer, BuildLogger, BuildSpinner, RegisteredPlugin, RegisterPluginOptions, PluginPlacement, ResolvedConfig, } from "@trigger.dev/core/v3/build";
|
|
2
|
+
export type { BuildManifest, WorkerManifest } from "@trigger.dev/core/v3/schemas";
|
|
3
|
+
export { binaryForRuntime, esbuildPlugin } from "@trigger.dev/core/v3/build";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export
|
|
1
|
+
export { binaryForRuntime, esbuildPlugin } from "@trigger.dev/core/v3/build";
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/extensions/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/extensions/index.ts"],"names":[],"mappings":"AAeA,OAAO,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC"}
|
|
@@ -4,6 +4,10 @@ export type PrismaExtensionOptions = {
|
|
|
4
4
|
schema: string;
|
|
5
5
|
migrate?: boolean;
|
|
6
6
|
version?: string;
|
|
7
|
+
/**
|
|
8
|
+
* Adds the `--sql` flag to the `prisma generate` command. This will generate the SQL files for the Prisma schema. Requires the `typedSql preview feature and prisma 5.19.0 or later.
|
|
9
|
+
*/
|
|
10
|
+
typedSql?: boolean;
|
|
7
11
|
/**
|
|
8
12
|
* The client generator to use. Set this param to prevent all generators in the prisma schema from being generated.
|
|
9
13
|
*
|
|
@@ -51,9 +51,28 @@ export class PrismaExtension {
|
|
|
51
51
|
const usingSchemaFolder = dirname(this._resolvedSchemaPath).endsWith("schema");
|
|
52
52
|
const commands = [];
|
|
53
53
|
let prismaDir;
|
|
54
|
-
const
|
|
55
|
-
|
|
56
|
-
|
|
54
|
+
const generatorFlags = [];
|
|
55
|
+
if (this.options.clientGenerator) {
|
|
56
|
+
generatorFlags.push(`--generator=${this.options.clientGenerator}`);
|
|
57
|
+
}
|
|
58
|
+
if (this.options.typedSql) {
|
|
59
|
+
generatorFlags.push(`--sql`);
|
|
60
|
+
const schemaDir = dirname(this._resolvedSchemaPath);
|
|
61
|
+
const prismaDir = dirname(schemaDir);
|
|
62
|
+
context.logger.debug(`Using typedSql`);
|
|
63
|
+
// Find all the files prisma/sql/*.sql
|
|
64
|
+
const sqlFiles = await readdir(join(prismaDir, "sql")).then((files) => files.filter((file) => file.endsWith(".sql")));
|
|
65
|
+
context.logger.debug(`Found sql files`, {
|
|
66
|
+
sqlFiles,
|
|
67
|
+
});
|
|
68
|
+
const sqlDestinationPath = join(manifest.outputPath, "prisma", "sql");
|
|
69
|
+
for (const file of sqlFiles) {
|
|
70
|
+
const destination = join(sqlDestinationPath, file);
|
|
71
|
+
const source = join(prismaDir, "sql", file);
|
|
72
|
+
context.logger.debug(`Copying the sql from ${source} to ${destination}`);
|
|
73
|
+
await cp(source, destination);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
57
76
|
if (usingSchemaFolder) {
|
|
58
77
|
const schemaDir = dirname(this._resolvedSchemaPath);
|
|
59
78
|
prismaDir = dirname(schemaDir);
|
|
@@ -71,7 +90,7 @@ export class PrismaExtension {
|
|
|
71
90
|
context.logger.debug(`Copying the prisma schema from ${source} to ${destination}`);
|
|
72
91
|
await cp(source, destination);
|
|
73
92
|
}
|
|
74
|
-
commands.push(`${binaryForRuntime(manifest.runtime)} node_modules/prisma/build/index.js generate ${
|
|
93
|
+
commands.push(`${binaryForRuntime(manifest.runtime)} node_modules/prisma/build/index.js generate ${generatorFlags.join(" ")}` // Don't add the --schema flag or this will fail
|
|
75
94
|
);
|
|
76
95
|
}
|
|
77
96
|
else {
|
|
@@ -84,7 +103,7 @@ export class PrismaExtension {
|
|
|
84
103
|
// Copy the prisma schema to the build output path
|
|
85
104
|
context.logger.debug(`Copying the prisma schema from ${this._resolvedSchemaPath} to ${schemaDestinationPath}`);
|
|
86
105
|
await cp(this._resolvedSchemaPath, schemaDestinationPath);
|
|
87
|
-
commands.push(`${binaryForRuntime(manifest.runtime)} node_modules/prisma/build/index.js generate --schema=./prisma/schema.prisma ${
|
|
106
|
+
commands.push(`${binaryForRuntime(manifest.runtime)} node_modules/prisma/build/index.js generate --schema=./prisma/schema.prisma ${generatorFlags.join(" ")}`);
|
|
88
107
|
}
|
|
89
108
|
const env = {};
|
|
90
109
|
if (this.options.migrate) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prisma.js","sourceRoot":"","sources":["../../../src/extensions/prisma.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAgC,MAAM,4BAA4B,CAAC;AAC5F,OAAO,MAAM,MAAM,aAAa,CAAC;AACjC,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,EAAE,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"prisma.js","sourceRoot":"","sources":["../../../src/extensions/prisma.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAgC,MAAM,4BAA4B,CAAC;AAC5F,OAAO,MAAM,MAAM,aAAa,CAAC;AACjC,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,EAAE,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAyCnD,MAAM,aAAa,GAAG,2BAA2B,CAAC;AAElD,MAAM,UAAU,eAAe,CAAC,OAA+B;IAC7D,OAAO,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E,OAAO;aAChB;YACD,KAAK,EAAE;gBACL,GAAG;aACJ;SACF,CAAC,CAAC;IACL,CAAC;CACF"}
|
|
@@ -1,5 +1,2 @@
|
|
|
1
1
|
import { BuildExtension } from "@trigger.dev/core/v3/build";
|
|
2
|
-
export
|
|
3
|
-
path?: string;
|
|
4
|
-
};
|
|
5
|
-
export declare function emitDecoratorMetadata(options?: EmitDecoratorMetadataOptions): BuildExtension;
|
|
2
|
+
export declare function emitDecoratorMetadata(): BuildExtension;
|
|
@@ -1,40 +1,54 @@
|
|
|
1
|
-
import { esbuildPlugin } from "@trigger.dev/core/v3/build";
|
|
2
1
|
import { readFile } from "node:fs/promises";
|
|
3
|
-
import { readTSConfig } from "pkg-types";
|
|
4
2
|
import typescriptPkg from "typescript";
|
|
5
3
|
const { transpileModule, ModuleKind } = typescriptPkg;
|
|
6
4
|
const decoratorMatcher = new RegExp(/((?<![(\s]\s*['"])@\w[.[\]\w\d]*\s*(?![;])[((?=\s)])/);
|
|
7
|
-
export function emitDecoratorMetadata(
|
|
8
|
-
return esbuildPlugin(plugin(options));
|
|
9
|
-
}
|
|
10
|
-
function plugin(options = {}) {
|
|
5
|
+
export function emitDecoratorMetadata() {
|
|
11
6
|
return {
|
|
12
7
|
name: "emitDecoratorMetadata",
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
8
|
+
onBuildStart(context) {
|
|
9
|
+
context.registerPlugin({
|
|
10
|
+
name: "emitDecoratorMetadata",
|
|
11
|
+
async setup(build) {
|
|
12
|
+
const { parseNative, TSConfckCache } = await import("tsconfck");
|
|
13
|
+
const cache = new TSConfckCache();
|
|
14
|
+
build.onLoad({ filter: /\.ts$/ }, async (args) => {
|
|
15
|
+
context.logger.debug("emitDecoratorMetadata onLoad", { args });
|
|
16
|
+
const { tsconfigFile, tsconfig } = await parseNative(args.path, {
|
|
17
|
+
ignoreNodeModules: true,
|
|
18
|
+
cache,
|
|
19
|
+
});
|
|
20
|
+
context.logger.debug("emitDecoratorMetadata parsed native tsconfig", {
|
|
21
|
+
tsconfig,
|
|
22
|
+
tsconfigFile,
|
|
23
|
+
args,
|
|
24
|
+
});
|
|
25
|
+
if (tsconfig.compilerOptions?.emitDecoratorMetadata !== true) {
|
|
26
|
+
context.logger.debug("emitDecoratorMetadata skipping", {
|
|
27
|
+
args,
|
|
28
|
+
tsconfig,
|
|
29
|
+
});
|
|
30
|
+
return undefined;
|
|
31
|
+
}
|
|
32
|
+
const ts = await readFile(args.path, "utf8");
|
|
33
|
+
if (!ts)
|
|
34
|
+
return undefined;
|
|
35
|
+
// Find the decorator and if there isn't one, return out
|
|
36
|
+
if (!decoratorMatcher.test(ts)) {
|
|
37
|
+
context.logger.debug("emitDecoratorMetadata skipping, no decorators found", {
|
|
38
|
+
args,
|
|
39
|
+
});
|
|
40
|
+
return undefined;
|
|
41
|
+
}
|
|
42
|
+
const program = transpileModule(ts, {
|
|
43
|
+
fileName: args.path,
|
|
44
|
+
compilerOptions: {
|
|
45
|
+
...tsconfig.compilerOptions,
|
|
46
|
+
module: ModuleKind.ES2022,
|
|
47
|
+
},
|
|
48
|
+
});
|
|
49
|
+
return { contents: program.outputText };
|
|
50
|
+
});
|
|
51
|
+
},
|
|
38
52
|
});
|
|
39
53
|
},
|
|
40
54
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typescript.js","sourceRoot":"","sources":["../../../src/extensions/typescript.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"typescript.js","sourceRoot":"","sources":["../../../src/extensions/typescript.ts"],"names":[],"m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AG,MAAM,QAAQ,CAAC,IAAI,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC;wBAE7C,IAAI,CAAC,EAAE;4BAAE,OAAO,SAAS,CAAC;wBAE1B,wDAAwD;wBACxD,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,CAAC;4BAC/B,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,qDAAqD,EAAE;gCAC1E,IAAI;6BACL,CAAC,CAAC;4BAEH,OAAO,SAAS,CAAC;wBACnB,CAAC;wBAED,MAAM,OAAO,GAAG,eAAe,CAAC,EAAE,EAAE;4BAClC,QAAQ,EAAE,IAAI,CAAC,IAAI;4BACnB,eAAe,EAAE;gCACf,GAAG,QAAQ,CAAC,eAAe;gCAC3B,MAAM,EAAE,UAAU,CAAC,MAAM;6BAC1B;yBACF,CAAC,CAAC;wBAEH,OAAO,EAAE,QAAQ,EAAE,OAAO,CAAC,UAAU,EAAE,CAAC;oBAC1C,CAAC,CAAC,CAAC;gBACL,CAAC;aACF,CAAC,CAAC;QACL,CAAC;KACF,CAAC;AACJ,CAAC"}
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export
|
|
1
|
+
export * from "./extensions/index.js";
|
package/dist/esm/index.js
CHANGED
package/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,iBAAiB;AACjB,cAAc,uBAAuB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trigger.dev/build",
|
|
3
|
-
"version": "0.0.0-prerelease-
|
|
3
|
+
"version": "0.0.0-prerelease-20240916123114",
|
|
4
4
|
"description": "trigger.dev build extensions",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"publishConfig": {
|
|
@@ -53,9 +53,10 @@
|
|
|
53
53
|
}
|
|
54
54
|
},
|
|
55
55
|
"dependencies": {
|
|
56
|
-
"@trigger.dev/core": "0.0.0-prerelease-
|
|
56
|
+
"@trigger.dev/core": "0.0.0-prerelease-20240916123114",
|
|
57
57
|
"pkg-types": "^1.1.3",
|
|
58
|
-
"tinyglobby": "^0.2.2"
|
|
58
|
+
"tinyglobby": "^0.2.2",
|
|
59
|
+
"tsconfck": "3.1.3"
|
|
59
60
|
},
|
|
60
61
|
"devDependencies": {
|
|
61
62
|
"@types/node": "20.14.14",
|