xcraft-core-utils 4.3.0 → 4.3.3

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.
Files changed (2) hide show
  1. package/lib/modules.js +15 -1
  2. package/package.json +1 -1
package/lib/modules.js CHANGED
@@ -93,7 +93,10 @@ exports.extractConfigDeps = (libDir, configJson) => {
93
93
 
94
94
  Object.keys(configJson).forEach((appId) => {
95
95
  const appCfg = configJson[appId];
96
- if (appCfg['xcraft-core-horde']) {
96
+ if (
97
+ appCfg['xcraft-core-horde'] &&
98
+ fse.existsSync(path.join(libDir, 'xcraft-core-horde'))
99
+ ) {
97
100
  deps['xcraft-core-horde'] = true;
98
101
  }
99
102
 
@@ -169,6 +172,17 @@ exports.extractAllJs = (libDir, modules) => {
169
172
  const location = path.join(libDir, mod);
170
173
  const files = xFs
171
174
  .lsall(location, true)
175
+ .filter((file) => {
176
+ const relativePath = file.substring(location.length + 1);
177
+ const items = relativePath.split(path.sep);
178
+ if (items.includes('node_modules')) {
179
+ return false;
180
+ }
181
+ if (items[0] === 'test' || items[0] === 'species') {
182
+ return false;
183
+ }
184
+ return true;
185
+ })
172
186
  .filter((file) => /\.js$/.test(file));
173
187
  list = list.concat(files);
174
188
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xcraft-core-utils",
3
- "version": "4.3.0",
3
+ "version": "4.3.3",
4
4
  "description": "Xcraft utils",
5
5
  "main": "index.js",
6
6
  "engines": {