@specdest/devkit 0.4.2 → 0.4.4

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@specdest/devkit",
3
- "version": "0.4.2",
3
+ "version": "0.4.4",
4
4
  "type": "module",
5
5
  "bin": {
6
6
  "specdest": "src/cli.js"
@@ -278,13 +278,18 @@ export async function canonicalCheck(projectRoot, source, options = {}) {
278
278
  group.ids.push(id);
279
279
  groups.set(key, group);
280
280
  }
281
- for (const group of groups.values()) {
282
- const args = [group.checkerPath, ...group.checkerArgs];
283
- if (targetMode !== 'full' && group.targeting.scope !== 'repository') {
284
- args.push('--target-mode', targetMode);
285
- for (const file of normalizedTargetFiles) args.push('--target-file', file);
286
- }
287
- const execution = await executor('node', args, projectRoot);
281
+ const groupExecutions = await Promise.all(
282
+ [...groups.values()].map(async (group) => {
283
+ const args = [group.checkerPath, ...group.checkerArgs];
284
+ if (targetMode !== 'full' && group.targeting.scope !== 'repository') {
285
+ args.push('--target-mode', targetMode);
286
+ for (const file of normalizedTargetFiles) args.push('--target-file', file);
287
+ }
288
+ const execution = await executor('node', args, projectRoot);
289
+ return { group, execution };
290
+ }),
291
+ );
292
+ for (const { group, execution } of groupExecutions) {
288
293
  const result = { status: execution.exitCode === 0 ? 'pass' : 'fail', ...execution };
289
294
  for (const id of group.ids) results[id] = result;
290
295
  if (execution.exitCode !== 0) exitCode = 1;