Index: lib/src/command/serve.dart |
diff --git a/lib/src/command/serve.dart b/lib/src/command/serve.dart |
index e43a9fc2bfa8f6c67b382bf74165e3f3f0d242f6..384832875ed22148eb9d7dbbd34d8b947113cc35 100644 |
--- a/lib/src/command/serve.dart |
+++ b/lib/src/command/serve.dart |
@@ -148,18 +148,17 @@ class ServeCommand extends BarbackCommand { |
} |
// Add two characters to account for "[" and "]". |
- var prefix = log.gray( |
+ var directory = log.gray( |
padRight("[${server.rootDirectory}]", directoryLength + 2)); |
server.results.listen((result) { |
- var buffer = new StringBuffer(); |
- buffer.write("$prefix "); |
- |
if (result.isSuccess) { |
- buffer.write( |
- "${log.green('GET')} ${result.url.path} $_arrow ${result.id}"); |
+ var prefix = "$directory ${log.green('GET')}"; |
+ log.collapsible("$prefix ${result.url.path} $_arrow ${result.id}", |
+ "$prefix Served ## assets."); |
} else { |
- buffer.write("${log.red('GET')} ${result.url.path} $_arrow"); |
+ var buffer = new StringBuffer(); |
+ buffer.write("$directory ${log.red('GET')} ${result.url.path} $_arrow"); |
var error = result.error.toString(); |
if (error.contains("\n")) { |
@@ -167,9 +166,9 @@ class ServeCommand extends BarbackCommand { |
} else { |
buffer.write(" $error"); |
} |
- } |
- log.message(buffer); |
+ log.error(buffer); |
+ } |
}, onError: _fatalError); |
log.message("Serving ${entrypoint.root.name} " |