mirror of
https://github.com/replicatedhq/troubleshoot.git
synced 2026-02-14 10:19:54 +00:00
fixed inline diff formatting
This commit is contained in:
@@ -470,14 +470,15 @@ func readLinesFromReader(reader io.Reader, maxBytes int) ([]string, error) {
|
|||||||
|
|
||||||
for scanner.Scan() {
|
for scanner.Scan() {
|
||||||
line := normalizeNewlines(scanner.Text())
|
line := normalizeNewlines(scanner.Text())
|
||||||
lineBytes := len(line) + 1 // +1 for newline
|
lineWithNL := line + "\n"
|
||||||
|
lineBytes := len(lineWithNL)
|
||||||
|
|
||||||
if totalBytes+lineBytes > maxBytes {
|
if totalBytes+lineBytes > maxBytes {
|
||||||
lines = append(lines, "... (content truncated due to size)")
|
lines = append(lines, "... (content truncated due to size)\n")
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
lines = append(lines, line)
|
lines = append(lines, lineWithNL)
|
||||||
totalBytes += lineBytes
|
totalBytes += lineBytes
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
BIN
supportbundle-bdoyal-getpixee-com-2yml5th-2025-08-13@21_46.tgz
Normal file
BIN
supportbundle-bdoyal-getpixee-com-2yml5th-2025-08-13@21_46.tgz
Normal file
Binary file not shown.
Reference in New Issue
Block a user