bun-workspaces 1.0.0-alpha.4 → 1.0.0-alpha.5
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/README.md +4 -0
- package/package.json +1 -1
- package/src/cli/projectCommands.ts +3 -7
package/README.md
CHANGED
|
@@ -79,6 +79,10 @@ bw script-info my-script --json
|
|
|
79
79
|
# in their `scripts` field
|
|
80
80
|
bw run my-script
|
|
81
81
|
|
|
82
|
+
# By default, a prefix is added to the script output with the workspace name
|
|
83
|
+
# This can be disabled with the --noPrefix option
|
|
84
|
+
bw run my-script --noPrefix
|
|
85
|
+
|
|
82
86
|
# Run a script for a specific workspace by its package.json name or alias from the config
|
|
83
87
|
bw run my-script my-workspace
|
|
84
88
|
|
package/package.json
CHANGED
|
@@ -370,20 +370,16 @@ const runScript = ({ program, project }: ProjectCommandsContext) => {
|
|
|
370
370
|
let failCount = 0;
|
|
371
371
|
results.forEach(({ success, workspaceName }) => {
|
|
372
372
|
if (!success) failCount++;
|
|
373
|
-
|
|
374
|
-
`${success ? "✅" : "❌"} ${workspaceName}: ${script}`,
|
|
375
|
-
);
|
|
373
|
+
logger.info(`${success ? "✅" : "❌"} ${workspaceName}: ${script}`);
|
|
376
374
|
});
|
|
377
375
|
|
|
378
376
|
const s = results.length === 1 ? "" : "s";
|
|
379
377
|
if (failCount) {
|
|
380
378
|
const message = `${failCount} of ${results.length} script${s} failed`;
|
|
381
|
-
|
|
379
|
+
logger.error(message);
|
|
382
380
|
process.exit(1);
|
|
383
381
|
} else {
|
|
384
|
-
|
|
385
|
-
`${results.length} script${s} ran successfully`,
|
|
386
|
-
);
|
|
382
|
+
logger.info(`${results.length} script${s} ran successfully`);
|
|
387
383
|
}
|
|
388
384
|
});
|
|
389
385
|
};
|