mirror of
https://github.com/oven-sh/bun
synced 2026-02-11 03:18:53 +00:00
Colorize build/resolve errors and add a ^
This commit is contained in:
@@ -834,9 +834,17 @@ pub const VirtualMachine = struct {
|
||||
|
||||
if (log.warnings > 0) {
|
||||
var writer = Output.errorWriter();
|
||||
for (log.msgs.items) |msg| {
|
||||
if (msg.kind == .warn) {
|
||||
msg.writeFormat(writer) catch {};
|
||||
if (Output.enable_ansi_colors) {
|
||||
for (log.msgs.items) |msg| {
|
||||
if (msg.kind == .warn) {
|
||||
msg.writeFormat(writer, true) catch {};
|
||||
}
|
||||
}
|
||||
} else {
|
||||
for (log.msgs.items) |msg| {
|
||||
if (msg.kind == .warn) {
|
||||
msg.writeFormat(writer, false) catch {};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user