@sireai/optimus 0.1.27 → 0.1.28

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.
@@ -160,17 +160,17 @@ async function runWithTerminalLoading(message, action) {
160
160
  process.stderr.write(`\r${frames[frameIndex]} ${message}`);
161
161
  const timer = setInterval(() => {
162
162
  frameIndex = (frameIndex + 1) % frames.length;
163
- process.stderr.write(`\r${frames[frameIndex]} ${message}`);
163
+ process.stderr.write(`\r${frames[frameIndex]}`);
164
164
  }, 160);
165
165
  try {
166
166
  const result = await action();
167
167
  clearInterval(timer);
168
- process.stderr.write(`\r[ok ] ${message}\n`);
168
+ process.stderr.write(`\r[ok ] ${message}\u001B[K\n`);
169
169
  return result;
170
170
  }
171
171
  catch (error) {
172
172
  clearInterval(timer);
173
- process.stderr.write(`\r[err] ${message}\n`);
173
+ process.stderr.write(`\r[err] ${message}\u001B[K\n`);
174
174
  throw error;
175
175
  }
176
176
  }