@o3r/core 11.2.0-prerelease.50 → 11.2.0-prerelease.52
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/builders/app-version/index.js +1 -1
- package/builders/ngc/index.js +1 -1
- package/builders/pattern-replacement/index.js +1 -1
- package/package.json +4 -4
- package/schematics/ng-add/index.js +1 -1
- package/schematics/ng-add/project-setup/index.js +1 -1
- package/schematics/rule-factories/additional-modules/index.js +1 -1
- package/schematics/rule-factories/store/index.js +1 -1
- package/schematics/schematics-update/index.d.ts.map +1 -1
- package/schematics/schematics-update/index.js +2 -1
- package/schematics/shared/presets/helpers.js +1 -1
|
@@ -23,7 +23,7 @@ exports.default = (0, architect_1.createBuilder)((0, utils_1.createBuilderWithMe
|
|
|
23
23
|
if (!fs.existsSync(packageJsonFile)) {
|
|
24
24
|
return PACKAGE_JSON_NOT_FOUND;
|
|
25
25
|
}
|
|
26
|
-
const packageJson = await fs.promises.readFile(packageJsonFile, { encoding: '
|
|
26
|
+
const packageJson = await fs.promises.readFile(packageJsonFile, { encoding: 'utf8' });
|
|
27
27
|
let version;
|
|
28
28
|
try {
|
|
29
29
|
version = JSON.parse(packageJson).version;
|
package/builders/ngc/index.js
CHANGED
|
@@ -25,7 +25,7 @@ exports.default = (0, architect_1.createBuilder)((0, utils_1.createBuilderWithMe
|
|
|
25
25
|
context.reportProgress(1, STEP_NUMBER, 'Handle package.json.');
|
|
26
26
|
const handlePackageJson = (distPath) => {
|
|
27
27
|
const packageJsonFile = path.resolve(context.currentDirectory, 'package.json');
|
|
28
|
-
const packageJsonString = fs.readFileSync(packageJsonFile, { encoding: '
|
|
28
|
+
const packageJsonString = fs.readFileSync(packageJsonFile, { encoding: 'utf8' });
|
|
29
29
|
const packageJson = JSON.parse(packageJsonString);
|
|
30
30
|
if (packageJson.otterBuilder && packageJson.otterBuilder.entryPoint && (typeof packageJson.otterBuilder.entryPoint === 'string')) {
|
|
31
31
|
const barrelName = path.parse(packageJson.otterBuilder.entryPoint).name;
|
|
@@ -19,7 +19,7 @@ exports.default = (0, architect_1.createBuilder)((0, utils_1.createBuilderWithMe
|
|
|
19
19
|
for (let i = 0; i < fileNames.length; i++) {
|
|
20
20
|
const filePath = fileNames[i];
|
|
21
21
|
context.reportProgress(i + 1, STEP_NUMBER, `Modifying ${filePath}`);
|
|
22
|
-
const fileContent = await fs.promises.readFile(filePath, { encoding: '
|
|
22
|
+
const fileContent = await fs.promises.readFile(filePath, { encoding: 'utf8' });
|
|
23
23
|
const newContent = fileContent.replace(new RegExp(options.searchValue, 'g'), options.replaceValue);
|
|
24
24
|
await fs.promises.writeFile(filePath, newContent);
|
|
25
25
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@o3r/core",
|
|
3
|
-
"version": "11.2.0-prerelease.
|
|
3
|
+
"version": "11.2.0-prerelease.52",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"@ngrx/entity": "~18.0.0",
|
|
26
26
|
"@ngrx/store": "~18.0.0",
|
|
27
27
|
"@nx/angular": "~19.5.0",
|
|
28
|
-
"@o3r/telemetry": "^11.2.0-prerelease.
|
|
28
|
+
"@o3r/telemetry": "^11.2.0-prerelease.52",
|
|
29
29
|
"@schematics/angular": "~18.2.0",
|
|
30
30
|
"chokidar": "^3.5.2",
|
|
31
31
|
"globby": "^11.1.0",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
}
|
|
60
60
|
},
|
|
61
61
|
"dependencies": {
|
|
62
|
-
"@o3r/schematics": "^11.2.0-prerelease.
|
|
62
|
+
"@o3r/schematics": "^11.2.0-prerelease.52",
|
|
63
63
|
"tslib": "^2.6.2",
|
|
64
64
|
"uuid": "^10.0.0"
|
|
65
65
|
},
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
"@ngrx/router-store": "~18.0.0",
|
|
70
70
|
"@ngrx/effects": "~18.0.0",
|
|
71
71
|
"@ngrx/store-devtools": "~18.0.0",
|
|
72
|
-
"@o3r/store-sync": "^11.2.0-prerelease.
|
|
72
|
+
"@o3r/store-sync": "^11.2.0-prerelease.52",
|
|
73
73
|
"@types/jest": "~29.5.2",
|
|
74
74
|
"nx": "~19.5.0",
|
|
75
75
|
"@typescript-eslint/parser": "^7.14.1",
|
|
@@ -19,7 +19,7 @@ const o3rDevDependencies = [
|
|
|
19
19
|
* @param options
|
|
20
20
|
*/
|
|
21
21
|
function ngAddFn(options) {
|
|
22
|
-
const corePackageJsonContent = JSON.parse(fs.readFileSync(path.resolve(__dirname, '..', '..', 'package.json'), { encoding: '
|
|
22
|
+
const corePackageJsonContent = JSON.parse(fs.readFileSync(path.resolve(__dirname, '..', '..', 'package.json'), { encoding: 'utf8' }));
|
|
23
23
|
const o3rCoreVersion = corePackageJsonContent.version;
|
|
24
24
|
const o3rVersionRange = options.exactO3rVersion ? o3rCoreVersion : `~${o3rCoreVersion}`;
|
|
25
25
|
return () => {
|
|
@@ -19,7 +19,7 @@ const index_2 = require("../utils/index");
|
|
|
19
19
|
const prepareProject = (options, dependenciesSetupConfig) => async (tree, context) => {
|
|
20
20
|
const coreSchematicsFolder = path.resolve(__dirname, '..');
|
|
21
21
|
const corePackageJsonPath = path.resolve(coreSchematicsFolder, '..', '..', 'package.json');
|
|
22
|
-
const corePackageJsonContent = JSON.parse(fs.readFileSync(corePackageJsonPath, { encoding: '
|
|
22
|
+
const corePackageJsonContent = JSON.parse(fs.readFileSync(corePackageJsonPath, { encoding: 'utf8' }));
|
|
23
23
|
if (!corePackageJsonContent) {
|
|
24
24
|
context.logger.error('Could not find @o3r/core package. Are you sure it is installed?');
|
|
25
25
|
}
|
|
@@ -11,7 +11,7 @@ const path = require("node:path");
|
|
|
11
11
|
const fs = require("node:fs");
|
|
12
12
|
const dependencies_1 = require("@schematics/angular/utility/dependencies");
|
|
13
13
|
const packageJsonPath = path.resolve(__dirname, '..', '..', '..', 'package.json');
|
|
14
|
-
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, { encoding: '
|
|
14
|
+
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, { encoding: 'utf8' }));
|
|
15
15
|
const ngrxStoreDevtoolsDep = '@ngrx/store-devtools';
|
|
16
16
|
/**
|
|
17
17
|
* Add additional modules for dev only
|
|
@@ -10,7 +10,7 @@ const ts = require("typescript");
|
|
|
10
10
|
const fs = require("node:fs");
|
|
11
11
|
const coreSchematicsFolder = path.resolve(__dirname, '..', '..');
|
|
12
12
|
const corePackageJsonPath = path.resolve(coreSchematicsFolder, '..', 'package.json');
|
|
13
|
-
const corePackageJsonContent = JSON.parse(fs.readFileSync(corePackageJsonPath, { encoding: '
|
|
13
|
+
const corePackageJsonContent = JSON.parse(fs.readFileSync(corePackageJsonPath, { encoding: 'utf8' }));
|
|
14
14
|
const o3rCoreVersion = corePackageJsonContent.version;
|
|
15
15
|
const ngrxEffectsDep = '@ngrx/effects';
|
|
16
16
|
const ngrxEntityDep = '@ngrx/entity';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/schematics-update/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,IAAI,EAA0B,MAAM,4BAA4B,CAAC;AAIvF,OAAO,EAAE,gCAAgC,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/schematics-update/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,IAAI,EAA0B,MAAM,4BAA4B,CAAC;AAIvF,OAAO,EAAE,gCAAgC,EAAE,MAAM,UAAU,CAAC;AAsE5D;;;GAGG;AACH,eAAO,MAAM,gBAAgB,qDAA4D,CAAC"}
|
|
@@ -5,6 +5,7 @@ const schematics_1 = require("@angular-devkit/schematics");
|
|
|
5
5
|
const schematics_2 = require("@o3r/schematics");
|
|
6
6
|
const path = require("node:path");
|
|
7
7
|
const otter_environment_1 = require("../rule-factories/otter-environment");
|
|
8
|
+
const node_fs_1 = require("node:fs");
|
|
8
9
|
/**
|
|
9
10
|
* add a new ngUpdate function
|
|
10
11
|
* @param options
|
|
@@ -16,7 +17,7 @@ function ngGenerateUpdateFn(options) {
|
|
|
16
17
|
const baseVersion = `${options.version}${options.version.indexOf('.') > -1 ? '' : '.0'}.0-alpha.0`;
|
|
17
18
|
const updateFunction = `updateV${sanitizedVersion}`;
|
|
18
19
|
const barrelPath = path.join(destination, 'schematics', 'ng-update', 'index.ts');
|
|
19
|
-
let migrationFilePath =
|
|
20
|
+
let migrationFilePath = JSON.parse((0, node_fs_1.readFileSync)(path.resolve(destination, '..', 'package.json'), { encoding: 'utf8' }))['ng-update'];
|
|
20
21
|
migrationFilePath = migrationFilePath && migrationFilePath.migrations;
|
|
21
22
|
migrationFilePath = migrationFilePath && path.join(destination, '..', migrationFilePath);
|
|
22
23
|
if (tree.exists(barrelPath)) {
|
|
@@ -12,7 +12,7 @@ const path = require("node:path");
|
|
|
12
12
|
*/
|
|
13
13
|
function defaultPresetRuleFactory(moduleToInstall, options = {}) {
|
|
14
14
|
return (tree, _context) => {
|
|
15
|
-
const corePackageJsonContent = JSON.parse(fs.readFileSync(path.resolve(__dirname, '..', '..', '..', 'package.json'), { encoding: '
|
|
15
|
+
const corePackageJsonContent = JSON.parse(fs.readFileSync(path.resolve(__dirname, '..', '..', '..', 'package.json'), { encoding: 'utf8' }));
|
|
16
16
|
const workspaceProject = options.projectName ? (0, schematics_2.getWorkspaceConfig)(tree)?.projects[options.projectName] : undefined;
|
|
17
17
|
if (!moduleToInstall.length) {
|
|
18
18
|
return tree;
|