mirror of
https://github.com/trezor/trezor-suite.git
synced 2026-03-20 14:18:16 +01:00
19 lines
390 B
JavaScript
19 lines
390 B
JavaScript
var stdin = process.openStdin();
|
|
|
|
var data = "";
|
|
|
|
stdin.on('data', function(chunk) {
|
|
data += chunk;
|
|
});
|
|
|
|
stdin.on('end', function() {
|
|
console.log(data);
|
|
const index = data.indexOf("] Total");
|
|
if (data[index-1] === '0') return process.exit(0);
|
|
return process.exit(1);
|
|
});
|
|
|
|
process.on('exit', function(code) {
|
|
return console.log(`Security check exited with code ${code}`);
|
|
});
|