MCPcopy Create free account
hub / github.com/dresende/node-orm2 / printTo

Function printTo

test/logging.js:15–22  ·  view source on GitHub ↗
(stream, prefix, color, text, params)

Source from the content-addressed store, hash-verified

13}
14
15function printTo(stream, prefix, color, text, params) {
16 params.unshift(text);
17 text = util.format.apply(util, params);
18
19 stream.write(printColor(color, true) + prefix + printColor(color) + text.replace(/\*\*(.+?)\*\*/, function (m, t) {
20 return printColor(color, true) + t + printColor(color);
21 }) + printColor(null) + "\n");
22}
23
24function printColor(color, bold) {
25 if (color === null) {

Callers 1

buildMethodFunction · 0.85

Calls 1

printColorFunction · 0.85

Tested by

no test coverage detected