Skip to content

Commit 4bcc619

Browse files
committed
Change print function
1 parent 12f7ad1 commit 4bcc619

File tree

1 file changed

+7
-12
lines changed

1 file changed

+7
-12
lines changed

functions/index.js

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,13 @@ var cmd = require('./command.js'),
88
k8sCommand = require('./kubernetes/k8sCommand.js').k8sCommand,
99
bojK8sCommand = require('./kubernetes/bojK8sCommand.js').bojK8sCommand;
1010

11-
function print(ins, outs, config, cb) {
12-
//console.log("PRINT", JSON.stringify(ins));
13-
ins.forEach(function(input) {
14-
//console.log("sigId=", input.sigId + ":", input.data[0])
15-
//console.log(JSON.stringify(input, null, 2));
16-
if (input.data && input.data[0].value) {
17-
console.log(input.data[0].value);
18-
} else {
19-
console.log(JSON.stringify(input, null, 2));
20-
}
21-
});
22-
cb(null, outs);
11+
function print(ins, outs, context, cb) {
12+
console.log("Running task", context.name, "(" + context.taskId + ")")
13+
console.log(context.executor)
14+
if (context.traceInfo) {
15+
console.log("Trace info:", context.traceInfo)
16+
}
17+
cb(null, outs);
2318
}
2419

2520
function print2(ins, outs, config, cb) {

0 commit comments

Comments
 (0)