mirror of
https://github.com/go-gitea/gitea.git
synced 2026-05-10 14:01:54 +02:00
fix(actions): fix blank lines after ::endgroup:: (#37597)
`endLogGroup` was incorrectly appending empty `<div>`s, producing a useless blank line after every group. Before and after: <img width="250" alt="Screenshot 2026-05-07 at 22 40 40" src="https://github.com/user-attachments/assets/8baf0fd0-99c8-4648-bf3f-edc6c4b197ec" /> <img width="250" alt="Screenshot 2026-05-07 at 22 37 12" src="https://github.com/user-attachments/assets/c45f28ae-1bbf-4b25-9d7b-281c19421f63" /> --------- Signed-off-by: silverwind <me@silverwind.io> Co-authored-by: Claude (Opus 4.7) <noreply@anthropic.com> Co-authored-by: Giteabot <teabot@gitea.io>
This commit is contained in:
parent
29676adfd3
commit
479bcdb503
@ -196,10 +196,9 @@ function beginLogGroup(stepIndex: number, startTime: number, line: LogLine, cmd:
|
||||
}
|
||||
|
||||
// end a log group
|
||||
function endLogGroup(stepIndex: number, startTime: number, line: LogLine, cmd: LogLineCommand) {
|
||||
function endLogGroup(stepIndex: number) {
|
||||
const el = getJobStepLogsContainer(stepIndex);
|
||||
el._stepLogsActiveContainer = undefined;
|
||||
el.append(createLogLine(stepIndex, startTime, line, cmd));
|
||||
}
|
||||
|
||||
// show/hide the step logs for a step
|
||||
@ -253,7 +252,7 @@ function appendLogs(stepIndex: number, startTime: number, logLines: LogLine[]) {
|
||||
beginLogGroup(stepIndex, startTime, line, cmd);
|
||||
continue;
|
||||
case 'endgroup':
|
||||
endLogGroup(stepIndex, startTime, line, cmd);
|
||||
endLogGroup(stepIndex);
|
||||
continue;
|
||||
}
|
||||
// the active logs container may change during the loop, for example: entering and leaving a group
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user