@eui/tools 6.2.26 → 6.2.27

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.
@@ -1 +1 @@
1
- 6.2.26
1
+ 6.2.27
package/CHANGELOG.md CHANGED
@@ -1,3 +1,12 @@
1
+ ## 6.2.27 (2022-11-15)
2
+
3
+ ##### Bug Fixes
4
+
5
+ * **other:**
6
+ * fetching latest fixed deps issue - MWP-9010 [MWP-9010](https://webgate.ec.europa.eu/CITnet/jira/browse/MWP-9010) ([c8c9792d](https://webgate.ec.europa.eu/CITnet/stash/scm/csdr/eui-tools.git/commits/c8c9792da91db89a46d820dfe465c397c2d920a5))
7
+
8
+ * * *
9
+ * * *
1
10
  ## 6.2.26 (2022-11-14)
2
11
 
3
12
  ##### Bug Fixes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eui/tools",
3
- "version": "6.2.26",
3
+ "version": "6.2.27",
4
4
  "tag": "latest",
5
5
  "license": "EUPL-1.1",
6
6
  "description": "eUI common tools and scripts",
package/sandbox.js CHANGED
@@ -1057,7 +1057,13 @@ const versionUtils = require('./scripts/csdr/version/version-utils');
1057
1057
  // return injectionUtils.routesReplacement.buildRoutes(project, 'TST', true);
1058
1058
  // })
1059
1059
 
1060
- const rootDirectory = fs.realpathSync(process.cwd());
1061
- const rootDirectory2 = process.cwd();
1062
-
1063
- console.log(rootDirectory, rootDirectory2);
1060
+ Promise.resolve()
1061
+ .then(() => {
1062
+ const prjName = 'my-workplace-host';
1063
+ const prj = configUtils.projects.getCsdrProject(prjName);
1064
+
1065
+ return installUtils.projects.getLocalProjectFixedDeps(prj);
1066
+ })
1067
+ .then((deps) => {
1068
+ console.log(deps);
1069
+ })
@@ -79,16 +79,11 @@ module.exports.getLocalProjectsDeps = () => {
79
79
  }
80
80
 
81
81
 
82
- const getLocalProjectFixedDeps = (prj) => {
82
+ const getLocalProjectFixedDeps = module.exports.getLocalProjectFixedDeps = (prj) => {
83
83
  tools.logTitle('Getting project fixed dependencies - not part of the composite');
84
84
 
85
85
  return Promise.resolve()
86
86
  .then(() => {
87
- return metadataUtils.package.getPackagesDeps('packages');
88
- })
89
-
90
- // extracting the fixed deps versions from metadata
91
- .then((pkgDeps) => {
92
87
  let deps = {};
93
88
 
94
89
  if (prj.fixedDependencies) {
@@ -96,7 +91,8 @@ const getLocalProjectFixedDeps = (prj) => {
96
91
  console.log(prj.fixedDependencies);
97
92
 
98
93
  prj.fixedDependencies.forEach((dep) => {
99
- const newDep = { [dep]: pkgDeps[dep] };
94
+ const pkg = configUtils.packages.getPackageByNpmPkg(dep, true);
95
+ const newDep = { [dep]: metadataUtils.package.getPackageVersionLast(pkg)};
100
96
  deps = { ...deps, ...newDep }
101
97
  })
102
98
  }
@@ -367,6 +367,18 @@ module.exports.getPackageVersionsLatest = (pkg) => {
367
367
  return;
368
368
  }
369
369
 
370
+ module.exports.getPackageVersionLast = (pkg) => {
371
+ const pkgVersionsJson = this.getPackageVersionsJson(pkg);
372
+
373
+
374
+
375
+ if (pkgVersionsJson) {
376
+ return pkgVersionsJson.versions.splice(-1)[0].version;
377
+ }
378
+
379
+ return;
380
+ }
381
+
370
382
 
371
383
  module.exports.getPackageVersionsByMajor = (pkg, major, isMaster) => {
372
384
  const pkgVersions = this.getPackageVersions(pkg);