Skip to content

Commit 271c7c2

Browse files
committed
remove trim content
1 parent e6ef962 commit 271c7c2

File tree

1 file changed

+0
-20
lines changed

1 file changed

+0
-20
lines changed

pkg/github/actions.go

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -781,26 +781,6 @@ func downloadLogContent(logURL string, tailLines int) (string, int, *http.Respon
781781
return content, len(lines), httpResp, nil
782782
}
783783

784-
// trimContent trims the content to a maximum length and returns the trimmed content and an original length
785-
func trimContent(content string, tailLines int) (string, int) {
786-
// Truncate to tail_lines if specified
787-
lineCount := 0
788-
if tailLines > 0 {
789-
790-
// Count backwards to find the nth newline from the end and a total number of lines
791-
for i := len(content) - 1; i >= 0 && lineCount < tailLines; i-- {
792-
if content[i] == '\n' {
793-
lineCount++
794-
// If we have reached the tailLines, trim the content
795-
if lineCount == tailLines {
796-
content = content[i+1:]
797-
}
798-
}
799-
}
800-
}
801-
return content, lineCount
802-
}
803-
804784
// RerunWorkflowRun creates a tool to re-run an entire workflow run
805785
func RerunWorkflowRun(getClient GetClientFn, t translations.TranslationHelperFunc) (tool mcp.Tool, handler server.ToolHandlerFunc) {
806786
return mcp.NewTool("rerun_workflow_run",

0 commit comments

Comments
 (0)