@onivoro/onix 20.0.47 → 20.0.49
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/package.json +1 -1
- package/src/executors/build-cli/executor.d.ts +2 -3
- package/src/executors/build-cli/executor.js +11 -14
- package/src/executors/build-cli/executor.js.map +1 -1
- package/src/executors/build-cli/schema.d.ts +1 -3
- package/src/executors/build-cli/schema.json +2 -7
- package/src/executors/playwright/executor.d.ts +2 -3
- package/src/executors/playwright/executor.js +11 -15
- package/src/executors/playwright/executor.js.map +1 -1
- package/src/executors/playwright/schema.d.ts +1 -0
- package/src/executors/playwright/schema.json +5 -1
- package/src/executors/typeorm/executor.d.ts +2 -3
- package/src/executors/typeorm/executor.js +7 -21
- package/src/executors/typeorm/executor.js.map +1 -1
- package/src/executors/typeorm/schema.d.ts +1 -1
- package/src/executors/typeorm/schema.json +2 -2
- package/src/functions/load-env-file.function.d.ts +1 -1
- package/src/functions/load-env-file.function.js.map +1 -1
package/package.json
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { PromiseExecutor } from '@nx/devkit';
|
|
2
1
|
import { ExecutorSchema } from './schema';
|
|
3
|
-
declare const
|
|
4
|
-
export default
|
|
2
|
+
declare const _default: import("@nx/devkit").PromiseExecutor<ExecutorSchema>;
|
|
3
|
+
export default _default;
|
|
@@ -3,18 +3,15 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
|
5
5
|
const child_process_1 = require("child_process");
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
exports.default = runExecutor;
|
|
6
|
+
const executor_factory_function_1 = require("../../functions/executor-factory.function");
|
|
7
|
+
const extract_project_build_outputs_function_1 = require("../../functions/extract-project-build-outputs.function");
|
|
8
|
+
exports.default = (0, executor_factory_function_1.executorFactory)((options, context) => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
|
|
9
|
+
const [outputPath] = (0, extract_project_build_outputs_function_1.extractProjectBuildOutputs)(context, context.projectName);
|
|
10
|
+
const tempPath = `${outputPath}/temp`;
|
|
11
|
+
const executableOutputPath = `${outputPath}/main.js`;
|
|
12
|
+
devkit_1.logger.info(`add a bin entry to root package.json pointing at this executable => ${executableOutputPath} and re-run this if the bin entry hasn't been added yet`);
|
|
13
|
+
const command = `npx nx build ${context.projectName} && echo '#! /usr/bin/env node' > ${tempPath} && cat ${executableOutputPath} >> ${tempPath} && mv ${tempPath} ${executableOutputPath} && chmod +x ${executableOutputPath} && npm link`;
|
|
14
|
+
devkit_1.logger.info(command);
|
|
15
|
+
(0, child_process_1.execSync)(command, { stdio: 'inherit' });
|
|
16
|
+
}));
|
|
20
17
|
//# sourceMappingURL=executor.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../onix/src/executors/build-cli/executor.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../onix/src/executors/build-cli/executor.ts"],"names":[],"mappings":";;;AAAA,uCAAoC;AAEpC,iDAAyC;AACzC,yFAA4E;AAC5E,mHAAoG;AAEpG,kBAAe,IAAA,2CAAe,EAAC,CAAO,OAAuB,EAAE,OAAO,EAAE,EAAE;IACxE,MAAM,CAAC,UAAU,CAAC,GAAG,IAAA,mEAA0B,EAAC,OAAO,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC;IAC9E,MAAM,QAAQ,GAAG,GAAG,UAAU,OAAO,CAAC;IACtC,MAAM,oBAAoB,GAAG,GAAG,UAAU,UAAU,CAAC;IACrD,eAAM,CAAC,IAAI,CAAC,uEAAuE,oBAAoB,yDAAyD,CAAC,CAAC;IAClK,MAAM,OAAO,GAAG,gBAAgB,OAAO,CAAC,WAAW,qCAAqC,QAAQ,WAAW,oBAAoB,OAAO,QAAQ,UAAU,QAAQ,IAAI,oBAAoB,gBAAgB,oBAAoB,cAAc,CAAC;IAE3O,eAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAErB,IAAA,wBAAQ,EAAC,OAAO,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;AAC1C,CAAC,CAAA,CAAC,CAAC"}
|
|
@@ -1,14 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json-schema.org/schema",
|
|
3
3
|
"version": 2,
|
|
4
|
-
"title": "
|
|
4
|
+
"title": "Build-cli executor",
|
|
5
5
|
"description": "",
|
|
6
6
|
"type": "object",
|
|
7
|
-
"properties": {
|
|
8
|
-
"moniker": {
|
|
9
|
-
"type": "string",
|
|
10
|
-
"description": "Lowercase single-word identifier used to consistently distinguish related projects and libraries"
|
|
11
|
-
}
|
|
12
|
-
},
|
|
7
|
+
"properties": {},
|
|
13
8
|
"required": []
|
|
14
9
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { PromiseExecutor } from '@nx/devkit';
|
|
2
1
|
import { ExecutorSchema } from './schema';
|
|
3
|
-
declare const
|
|
4
|
-
export default
|
|
2
|
+
declare const _default: import("@nx/devkit").PromiseExecutor<ExecutorSchema>;
|
|
3
|
+
export default _default;
|
|
@@ -3,19 +3,15 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
|
5
5
|
const child_process_1 = require("child_process");
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
return { success: false };
|
|
18
|
-
}
|
|
19
|
-
});
|
|
20
|
-
exports.default = runExecutor;
|
|
6
|
+
const executor_factory_function_1 = require("../../functions/executor-factory.function");
|
|
7
|
+
const load_env_file_function_1 = require("../../functions/load-env-file.function");
|
|
8
|
+
const extract_project_configuration_function_1 = require("../../functions/extract-project-configuration.function");
|
|
9
|
+
exports.default = (0, executor_factory_function_1.executorFactory)((options, context) => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
|
|
10
|
+
const { envFile } = options;
|
|
11
|
+
(0, load_env_file_function_1.loadEnvFile)(envFile);
|
|
12
|
+
const root = (0, extract_project_configuration_function_1.extractProjectConfiguration)(context, context.projectName).root;
|
|
13
|
+
const command = `playwright test -c ${root}/playwright.config.ts`;
|
|
14
|
+
devkit_1.logger.info(command);
|
|
15
|
+
(0, child_process_1.execSync)(command, { stdio: 'inherit' });
|
|
16
|
+
}));
|
|
21
17
|
//# sourceMappingURL=executor.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../onix/src/executors/playwright/executor.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../onix/src/executors/playwright/executor.ts"],"names":[],"mappings":";;;AAAA,uCAAoC;AAEpC,iDAAyC;AACzC,yFAA4E;AAC5E,mFAAqE;AACrE,mHAAqG;AAErG,kBAAe,IAAA,2CAAe,EAAC,CAAO,OAAuB,EAAE,OAAO,EAAE,EAAE;IACxE,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC;IAE5B,IAAA,oCAAW,EAAC,OAAO,CAAC,CAAC;IAErB,MAAM,IAAI,GAAG,IAAA,oEAA2B,EAAC,OAAO,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC,IAAI,CAAC;IAE5E,MAAM,OAAO,GAAG,sBAAsB,IAAI,uBAAuB,CAAC;IAElE,eAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAErB,IAAA,wBAAQ,EAAC,OAAO,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;AAC1C,CAAC,CAAA,CAAC,CAAC"}
|
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json-schema.org/schema",
|
|
3
3
|
"version": 2,
|
|
4
|
-
"title": "
|
|
4
|
+
"title": "Playwright executor",
|
|
5
5
|
"description": "",
|
|
6
6
|
"type": "object",
|
|
7
7
|
"properties": {
|
|
8
|
+
"envFile": {
|
|
9
|
+
"type": "string",
|
|
10
|
+
"description": "Path and name of the .env file to load"
|
|
11
|
+
}
|
|
8
12
|
},
|
|
9
13
|
"required": []
|
|
10
14
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { PromiseExecutor } from '@nx/devkit';
|
|
2
1
|
import { ExecutorSchema } from './schema';
|
|
3
|
-
declare const
|
|
4
|
-
export default
|
|
2
|
+
declare const _default: import("@nx/devkit").PromiseExecutor<ExecutorSchema>;
|
|
3
|
+
export default _default;
|
|
@@ -1,26 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
|
-
const devkit_1 = require("@nx/devkit");
|
|
5
4
|
const child_process_1 = require("child_process");
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
(0, child_process_1.execSync)(`npm run typeorm -- -d ${ormConfigPath} migration:${runOrRevert} -t=false`, { stdio: 'inherit' });
|
|
15
|
-
return {
|
|
16
|
-
success: true,
|
|
17
|
-
};
|
|
18
|
-
}
|
|
19
|
-
catch (error) {
|
|
20
|
-
return {
|
|
21
|
-
success: false,
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
});
|
|
25
|
-
exports.default = executor;
|
|
5
|
+
const load_env_file_function_1 = require("../../functions/load-env-file.function");
|
|
6
|
+
const executor_factory_function_1 = require("../../functions/executor-factory.function");
|
|
7
|
+
exports.default = (0, executor_factory_function_1.executorFactory)((options, context) => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
|
|
8
|
+
const { envFile, ormConfigPath, runOrRevert } = options;
|
|
9
|
+
(0, load_env_file_function_1.loadEnvFile)(envFile);
|
|
10
|
+
(0, child_process_1.execSync)(`npm run typeorm -- -d ${ormConfigPath} migration:${runOrRevert} -t=false`, { stdio: 'inherit' });
|
|
11
|
+
}));
|
|
26
12
|
//# sourceMappingURL=executor.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../onix/src/executors/typeorm/executor.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../onix/src/executors/typeorm/executor.ts"],"names":[],"mappings":";;;AAEA,iDAAyC;AACzC,mFAAqE;AACrE,yFAA4E;AAE5E,kBAAe,IAAA,2CAAe,EAAC,CAC7B,OAAuB,EACvB,OAAwB,EACxB,EAAE;IACF,MAAM,EAAE,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,GAAG,OAAO,CAAC;IAExD,IAAA,oCAAW,EAAC,OAAO,CAAC,CAAC;IAErB,IAAA,wBAAQ,EAAC,yBAAyB,aAAa,cAAc,WAAW,WAAW,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;AAC7G,CAAC,CAAA,CAAC,CAAC"}
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"type": "string",
|
|
10
10
|
"description": "TypeORM CLI command: 'run' or 'revert'"
|
|
11
11
|
},
|
|
12
|
-
"
|
|
12
|
+
"envFile": {
|
|
13
13
|
"type": "string",
|
|
14
14
|
"description": "Path and name of the .env file to load"
|
|
15
15
|
},
|
|
@@ -19,6 +19,6 @@
|
|
|
19
19
|
}
|
|
20
20
|
},
|
|
21
21
|
"required": [
|
|
22
|
-
"
|
|
22
|
+
"envFile", "ormConfigPath"
|
|
23
23
|
]
|
|
24
24
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function loadEnvFile(envFile
|
|
1
|
+
export declare function loadEnvFile(envFile?: string | undefined): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"load-env-file.function.js","sourceRoot":"","sources":["../../../../onix/src/functions/load-env-file.function.ts"],"names":[],"mappings":";;AAIA,kCAQC;AAZD,uCAAoC;AACpC,2BAAgC;AAChC,qCAAyD;AAEzD,SAAgB,WAAW,CAAC,
|
|
1
|
+
{"version":3,"file":"load-env-file.function.js","sourceRoot":"","sources":["../../../../onix/src/functions/load-env-file.function.ts"],"names":[],"mappings":";;AAIA,kCAQC;AAZD,uCAAoC;AACpC,2BAAgC;AAChC,qCAAyD;AAEzD,SAAgB,WAAW,CAAC,OAA4B;IACpD,IAAI,OAAO,EAAE,CAAC;QACV,IAAG,IAAA,eAAU,EAAC,OAAO,CAAC,EAAE,CAAC;YACrB,IAAA,qBAAe,EAAC,OAAO,CAAC,CAAC;QAC7B,CAAC;aAAM,CAAC;YACJ,eAAM,CAAC,IAAI,CAAC,+BAA+B,OAAO,kBAAkB,CAAC,CAAC;QAC1E,CAAC;IACL,CAAC;AACL,CAAC"}
|