mirror of
https://github.com/QwenLM/qwen-code.git
synced 2026-04-28 19:52:02 +00:00
Fix diff rendering in windows. (#7254)
This commit is contained in:
parent
cd2e237c73
commit
af4fe611ed
2 changed files with 11 additions and 13 deletions
|
|
@ -6,7 +6,6 @@
|
|||
|
||||
import type React from 'react';
|
||||
import { Box, Text } from 'ink';
|
||||
import { EOL } from 'node:os';
|
||||
import { Colors } from '../../colors.js';
|
||||
import crypto from 'node:crypto';
|
||||
import { colorizeCode, colorizeLine } from '../../utils/CodeColorizer.js';
|
||||
|
|
@ -21,7 +20,7 @@ interface DiffLine {
|
|||
}
|
||||
|
||||
function parseDiffWithLineNumbers(diffContent: string): DiffLine[] {
|
||||
const lines = diffContent.split(EOL);
|
||||
const lines = diffContent.split('\n');
|
||||
const result: DiffLine[] = [];
|
||||
let currentOldLine = 0;
|
||||
let currentNewLine = 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue