Skip to content

Commit 0db3efa

Browse files
committed
fix: do not eat linefeed when no-consoleClear
1 parent 27de707 commit 0db3efa

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ EXAMPLES
102102
│[info]:Start Script: ...
103103
```
104104

105-
_See code: [src/commands/run/index.ts](https://github.com/offline-ai/cli-plugin-core.js/blob/v0.11.3/src/commands/run/index.ts)_
105+
_See code: [src/commands/run/index.ts](https://github.com/offline-ai/cli-plugin-core.js/blob/v0.11.4/src/commands/run/index.ts)_
106106
<!-- commandsstop -->
107107

108108
# Credit

src/lib/run-script.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@ export async function runScript(filename: string, options: IRunScriptOptions) {
426426
llmLastContent = ''
427427
}
428428

429-
if (options.streamEcho === 'line' && countRegexMatches(llmLastContent, /[\n\r]/) >= 1) {
429+
if (options.consoleClear && options.streamEcho === 'line' && countRegexMatches(llmLastContent, /[\n\r]/) >= 1) {
430430
// logUpdate.clear(options.consoleClear)
431431
llmLastContent = ''
432432
}

0 commit comments

Comments
 (0)