codify-plugin-lib 1.0.182-beta15 → 1.0.182-beta17

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.
@@ -6,6 +6,7 @@ import * as fs from 'node:fs/promises';
6
6
  import stripAnsi from 'strip-ansi';
7
7
  import { debugLog } from '../utils/debug.js';
8
8
  import { Shell, Utils } from '../utils/index.js';
9
+ import { VerbosityLevel } from '../utils/verbosity-level.js';
9
10
  import { SpawnError } from './index.js';
10
11
  import { PromiseQueue } from './promise-queue.js';
11
12
  EventEmitter.defaultMaxListeners = 1000;
@@ -50,7 +51,6 @@ export class BackgroundPty {
50
51
  let output = '';
51
52
  cat.stdout.on('data', (data) => {
52
53
  output += data.toString();
53
- process.stdout.write(data);
54
54
  if (output.includes('%%%done%%%"')) {
55
55
  const truncOutput = output.replace('%%%done%%%"\n', '');
56
56
  const [data, exit] = truncOutput.split('%%%');
@@ -67,9 +67,9 @@ export class BackgroundPty {
67
67
  }
68
68
  else {
69
69
  // Print to stdout if the verbosity level is above 0
70
- // if (VerbosityLevel.get() > 0) {
71
- // process.stdout.write(data);
72
- // }
70
+ if (VerbosityLevel.get() > 0) {
71
+ process.stdout.write(data);
72
+ }
73
73
  }
74
74
  });
75
75
  this.promiseQueue.run(async () => new Promise((resolve) => {
@@ -106,18 +106,6 @@ export class BackgroundPty {
106
106
  await this.promiseQueue.run(async () => {
107
107
  let outputBuffer = '';
108
108
  return new Promise(resolve => {
109
- // zsh-specific commands
110
- // switch (Utils.getShell()) {
111
- // case Shell.ZSH: {
112
- // this.basePty.write('setopt HIST_NO_STORE;\n');
113
- // break;
114
- // }
115
- //
116
- // default: {
117
- // this.basePty.write('export HISTIGNORE=\'history*\';\n');
118
- // break;
119
- // }
120
- // }
121
109
  this.basePty.write(' unset PS1;\n');
122
110
  this.basePty.write(' unset PS0;\n');
123
111
  this.basePty.write(' echo setup complete\\"\n');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codify-plugin-lib",
3
- "version": "1.0.182-beta15",
3
+ "version": "1.0.182-beta17",
4
4
  "description": "Library plugin library",
5
5
  "main": "dist/index.js",
6
6
  "typings": "dist/index.d.ts",
@@ -64,8 +64,6 @@ export class BackgroundPty implements IPty {
64
64
  cat.stdout.on('data', (data) => {
65
65
  output += data.toString();
66
66
 
67
- process.stdout.write(data);
68
-
69
67
  if (output.includes('%%%done%%%"')) {
70
68
  const truncOutput = output.replace('%%%done%%%"\n', '');
71
69
  const [data, exit] = truncOutput.split('%%%');
@@ -83,9 +81,9 @@ export class BackgroundPty implements IPty {
83
81
  });
84
82
  } else {
85
83
  // Print to stdout if the verbosity level is above 0
86
- // if (VerbosityLevel.get() > 0) {
87
- // process.stdout.write(data);
88
- // }
84
+ if (VerbosityLevel.get() > 0) {
85
+ process.stdout.write(data);
86
+ }
89
87
  }
90
88
  })
91
89
 
@@ -132,19 +130,6 @@ export class BackgroundPty implements IPty {
132
130
  let outputBuffer = '';
133
131
 
134
132
  return new Promise(resolve => {
135
- // zsh-specific commands
136
- // switch (Utils.getShell()) {
137
- // case Shell.ZSH: {
138
- // this.basePty.write('setopt HIST_NO_STORE;\n');
139
- // break;
140
- // }
141
- //
142
- // default: {
143
- // this.basePty.write('export HISTIGNORE=\'history*\';\n');
144
- // break;
145
- // }
146
- // }
147
-
148
133
  this.basePty.write(' unset PS1;\n');
149
134
  this.basePty.write(' unset PS0;\n')
150
135
  this.basePty.write(' echo setup complete\\"\n')