@eui/tools 6.21.91 → 6.21.92

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.21.91
1
+ 6.21.92
package/CHANGELOG.md CHANGED
@@ -1,3 +1,12 @@
1
+ ## 6.21.92 (2025-07-04)
2
+
3
+ ##### Chores
4
+
5
+ * **other:**
6
+ * adapted sdlc migration script for remotes - MWP-11955 [MWP-11955](https://webgate.ec.europa.eu/CITnet/jira/browse/MWP-11955) ([5fb4904a](https://webgate.ec.europa.eu/CITnet/stash/scm/csdr/eui-tools.git/commits/5fb4904a5202c3cb402f736de9fd1a6489c8747b))
7
+
8
+ * * *
9
+ * * *
1
10
  ## 6.21.91 (2025-07-03)
2
11
 
3
12
  ##### Chores
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eui/tools",
3
- "version": "6.21.91",
3
+ "version": "6.21.92",
4
4
  "tag": "latest",
5
5
  "license": "EUPL-1.1",
6
6
  "description": "eUI common tools and scripts",
@@ -6,49 +6,86 @@ const tools = require('../tools');
6
6
  module.exports.migrate = (pkg) => {
7
7
  return Promise.resolve()
8
8
  .then(() => {
9
- tools.logTitle(`Migrating package ${pkg.name}`);
9
+ // tools.logTitle(`Migrating package ${pkg.name}`);
10
10
 
11
- console.log(pkg);
11
+ // console.log(pkg);
12
12
 
13
- tools.logInfo('Replacing .csdr/packages config');
13
+ // tools.logInfo('Replacing .csdr/packages config');
14
14
 
15
- let pkgDef = {
16
- "name": pkg.name,
17
- "npmPkg": pkg.npmPkg,
18
- "repository": `myworkplace-ui/${pkg.name}.git`,
19
- "sdlc": true
20
- };
21
- console.log(pkgDef);
15
+ // let pkgDef = {
16
+ // "name": pkg.name,
17
+ // "npmPkg": pkg.npmPkg,
18
+ // "repository": `myworkplace-ui/${pkg.name}.git`,
19
+ // "sdlc": true
20
+ // };
21
+ // console.log(pkgDef);
22
22
 
23
- const packagesConfigFile = path.join(process.cwd(), '.csdr', '.euirc-csdr-packages.json');
24
- const packagesConfig = require(packagesConfigFile);
23
+ // const packagesConfigFile = path.join(process.cwd(), '.csdr', '.euirc-csdr-packages.json');
24
+ // const packagesConfig = require(packagesConfigFile);
25
25
 
26
- packagesConfig[pkg.name] = pkgDef;
26
+ // packagesConfig[pkg.name] = pkgDef;
27
27
 
28
- tools.writeJsonFileSync(packagesConfigFile, packagesConfig);
28
+ // tools.writeJsonFileSync(packagesConfigFile, packagesConfig);
29
29
 
30
30
 
31
- tools.logInfo('Adding entry in the SDLC config');
31
+ // tools.logInfo('Adding entry in the SDLC config');
32
32
 
33
- pkgDef = {
34
- "npmPkg": pkg.npmPkg,
35
- "subgroup": 'myworkplace-ui'
36
- };
37
- console.log(pkgDef);
33
+ // pkgDef = {
34
+ // "npmPkg": pkg.npmPkg,
35
+ // "subgroup": 'myworkplace-ui'
36
+ // };
37
+ // console.log(pkgDef);
38
38
 
39
- const packazgesSDLCConfigFile = path.join(process.cwd(), '.sdlc-config', '.euirc-packages.json');
40
- const packagesSDLCConfig = require(packazgesSDLCConfigFile);
39
+ // const packazgesSDLCConfigFile = path.join(process.cwd(), '.sdlc-config', '.euirc-packages.json');
40
+ // const packagesSDLCConfig = require(packazgesSDLCConfigFile);
41
41
 
42
- packagesSDLCConfig[pkg.name] = pkgDef;
42
+ // packagesSDLCConfig[pkg.name] = pkgDef;
43
43
 
44
- tools.writeJsonFileSync(packazgesSDLCConfigFile, packagesSDLCConfig);
44
+ // tools.writeJsonFileSync(packazgesSDLCConfigFile, packagesSDLCConfig);
45
45
 
46
46
 
47
- tools.logInfo('Adapting files for SDLC repository');
48
47
 
49
- tools.copydirFiles(path.join(__dirname, 'skeleton', '19.x'), pkg.paths.root);
48
+ // tools.logInfo('Adapting files for SDLC repository');
50
49
 
51
- tools.move(path.join(pkg.paths.root, '.gitignore_TO_REPLACE'), path.join(pkg.paths.root, '.gitignore'));
50
+ // tools.copydirFiles(path.join(__dirname, 'skeleton', '19.x'), pkg.paths.root);
51
+
52
+ // tools.move(path.join(pkg.paths.root, '.gitignore_TO_REPLACE'), path.join(pkg.paths.root, '.gitignore'));
53
+
54
+
55
+
56
+ tools.logInfo('Duplicating remote config');
57
+
58
+ const remotePrefix = `${pkg.npmPkg.split('/')[0].substr(1)}-${pkg.npmPkg.split('/')[1]}`;
59
+
60
+ const currentRemoteName = `${remotePrefix}-eui19-remote-el-ui`;
61
+ const newRemoteName = `${remotePrefix}-remote-eui19`;
62
+
63
+ console.log('Current remote : ', currentRemoteName);
64
+ console.log('New remote : ', newRemoteName);
65
+
66
+ const currentRemotePath = path.join(process.cwd(), 'packages', 'csdr-remotes-config', 'assets', currentRemoteName);
67
+ const newRemotePath = path.join(process.cwd(), '.sdlc-config', 'remotes', newRemoteName);
68
+
69
+ if (!tools.isDirExists(currentRemotePath)) {
70
+ throw new Error(`${currentRemotePath} NOT FOUND, contact support`);
71
+ }
72
+
73
+ tools.copydir(currentRemotePath, newRemotePath);
74
+
75
+ const currentRemoteConfig = require(path.join(process.cwd(), '.csdr', '.euirc-csdr-remotes.json'))[currentRemoteName];
76
+
77
+ const remoteSDLCConfigFile = path.join(process.cwd(), '.sdlc-config', 'remotes', '.euirc-remotes.json');
78
+ const remotesSDLCConfig = require(remoteSDLCConfigFile);
79
+
80
+ delete currentRemoteConfig['slack'];
81
+
82
+ currentRemoteConfig['npmPkg'] = currentRemoteConfig['npmPkg'].replace('eui19-remote-el', 'remote-eui19');
83
+
84
+ currentRemoteConfig['msteams'] = { "channel": "pipeline-ui-mwp" };
85
+
86
+ remotesSDLCConfig[newRemoteName] = currentRemoteConfig;
87
+
88
+ tools.writeJsonFileSync(remoteSDLCConfigFile, remotesSDLCConfig);
52
89
  })
53
90
  .catch((e) => {
54
91
  console.log(e);