1 | "use strict";
|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
3 | const index_1 = require("./index");
|
4 | const options = {
|
5 | scriptPath: 'C:\\dev\\python-shell',
|
6 | env: { PYTHONIOENCODING: 'utf8' },
|
7 | };
|
8 | const pyTeste = new index_1.PythonShell('a.py', options);
|
9 | pyTeste
|
10 | .on('message', (line) => {
|
11 | console.log(line);
|
12 | })
|
13 | .on('stderr', (std) => {
|
14 | console.log(std);
|
15 | })
|
16 | .on('error', err => {
|
17 | console.log('err');
|
18 | console.log(err);
|
19 | })
|
20 | .on('close', () => {
|
21 | console.log('Programa finalizado');
|
22 | });
|
23 |
|
\ | No newline at end of file |