pinokiod 3.19.22 → 3.19.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/kernel/shell.js +9 -0
  2. package/package.json +1 -1
package/kernel/shell.js CHANGED
@@ -258,6 +258,9 @@ class Shell {
258
258
  this.params = params
259
259
  if (this.params.shell) {
260
260
  this.shell = this.params.shell
261
+ if (this.shell === "bash") {
262
+ this.args = ["--noprofile", "--norc"]
263
+ }
261
264
  }
262
265
 
263
266
  // 3. path => path can be http, relative, absolute
@@ -455,6 +458,7 @@ class Shell {
455
458
  }
456
459
  this.prompt_pattern = await this.prompt(params.path)
457
460
  this.cb = cb
461
+ console.log("This.exec")
458
462
  let r = await this.exec(params)
459
463
  return r
460
464
  }
@@ -482,6 +486,7 @@ class Shell {
482
486
 
483
487
  //let re = /([\r\n]+[^\r\n]+)(\1)/gs
484
488
  let re = /(.+)(\1)/gs
489
+ console.log("Prompt spawn")
485
490
  let term = pty.spawn(this.shell, this.args, config)
486
491
  let ready
487
492
  let vt = new Terminal({
@@ -491,6 +496,7 @@ class Shell {
491
496
  vt.loadAddon(vts)
492
497
 
493
498
  let queue = fastq((data, cb) => {
499
+ console.log("Vt.write", data)
494
500
  vt.write(data, () => {
495
501
  let buf = vts.serialize()
496
502
  let re = /(.+)echo pinokio[\r\n]+pinokio[\r\n]+(\1)/gs
@@ -510,6 +516,7 @@ class Shell {
510
516
  cb()
511
517
  }, 1)
512
518
  term.onData((data) => {
519
+ console.log({ data })
513
520
  if (ready) {
514
521
  queue.push(data)
515
522
  } else {
@@ -973,8 +980,10 @@ class Shell {
973
980
  if (!this.ptyProcess) {
974
981
  // ptyProcess doesn't exist => create
975
982
  this.done = false
983
+ console.log("EXEC SPAWN")
976
984
  this.ptyProcess = pty.spawn(this.shell, this.args, config)
977
985
  this.ptyProcess.onData((data) => {
986
+ console.log("EXEC ONDATA", data)
978
987
  if (!this.monitor) {
979
988
  this.monitor = ""
980
989
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pinokiod",
3
- "version": "3.19.22",
3
+ "version": "3.19.24",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {