let str;
const net = require('net');
const client = net.createConnection({
host: '127.0.0.1',
port: 3545
}, () => {
client.write('status\r\n');
});
client.on('data', (data) => {
str = data;
client.end();
});
client.on('end', () => {
});
console.log(str)