electron-builder-util
Advanced tools
Comparing version 11.0.0 to 11.2.0
@@ -68,19 +68,39 @@ "use strict"; | ||
const dirs = []; | ||
yield (_bluebirdLstC2 || _load_bluebirdLstC2()).default.map(childNames, function (name) { | ||
// our handler is async, but we should add sorted files, so, we add file to result not in the mapper, but after map | ||
const sortedFilePaths = yield (_bluebirdLstC2 || _load_bluebirdLstC2()).default.map(childNames, function (name) { | ||
const filePath = dirPath + _path.sep + name; | ||
return (0, (_fsExtraP || _load_fsExtraP()).lstat)(filePath).then(function (stat) { | ||
if (filter != null && !filter(filePath, stat)) { | ||
return; | ||
return null; | ||
} | ||
if (stat.isDirectory()) { | ||
dirs.push(filePath); | ||
const consumerResult = consumer == null ? null : consumer(filePath, stat, dirPath); | ||
if (consumerResult == null || !("then" in consumerResult)) { | ||
if (stat.isDirectory()) { | ||
dirs.push(name); | ||
return null; | ||
} else { | ||
return filePath; | ||
} | ||
} else { | ||
result.push(filePath); | ||
return consumerResult.then(function (it) { | ||
// asarUtil can return modified stat (symlink handling) | ||
if ((it != null && "isDirectory" in it ? it : stat).isDirectory()) { | ||
dirs.push(name); | ||
return null; | ||
} else { | ||
return filePath; | ||
} | ||
}); | ||
} | ||
return consumer == null ? null : consumer(filePath, stat, dirPath); | ||
}); | ||
}, CONCURRENCY); | ||
for (let i = dirs.length - 1; i > -1; i--) { | ||
queue.push(dirs[i]); | ||
for (const child of sortedFilePaths) { | ||
if (child != null) { | ||
result.push(child); | ||
} | ||
} | ||
dirs.sort(); | ||
for (const child of dirs) { | ||
queue.push(dirPath + _path.sep + child); | ||
} | ||
} | ||
@@ -87,0 +107,0 @@ return result; |
{ | ||
"name": "electron-builder-util", | ||
"version": "11.2.0", | ||
"main": "out/util.js", | ||
@@ -23,8 +24,7 @@ "author": "Vladimir Krivosheev", | ||
"ansi-escapes": "^1.4.0", | ||
"electron-builder-http": "11.0.0", | ||
"electron-builder-http": "~11.2.0", | ||
"source-map-support": "^0.4.8", | ||
"7zip-bin": "^2.0.4" | ||
}, | ||
"typings": "./out/electron-builder-util.d.ts", | ||
"version": "11.0.0" | ||
"typings": "./out/electron-builder-util.d.ts" | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
98168
1029
+ Addedelectron-builder-http@11.2.0(transitive)
- Removedelectron-builder-http@11.0.0(transitive)