MCPcopy Create free account
hub / github.com/driangle/taskmd / writeFileChangeText

Function writeFileChangeText

apps/cli/internal/cli/feed.go:160–173  ·  view source on GitHub ↗
(f feed.FileChange, r *lipgloss.Renderer)

Source from the content-addressed store, hash-verified

158}
159
160func writeFileChangeText(f feed.FileChange, r *lipgloss.Renderer) {
161 statusTag := fileStatusTag(f)
162 taskRef := ""
163 if f.TaskID != "" {
164 taskRef = fmt.Sprintf(" (%s)", formatTaskID(f.TaskID, r))
165 }
166
167 summary := formatChangeSummary(f)
168 if summary != "" {
169 fmt.Printf(" %s %s%s: %s\n", statusTag, f.Path, taskRef, summary)
170 } else {
171 fmt.Printf(" %s %s%s\n", statusTag, f.Path, taskRef)
172 }
173}
174
175// formatChangeSummary builds a compact one-line summary of field and subtask changes.
176func formatChangeSummary(f feed.FileChange) string {

Callers 1

writeFeedTextFunction · 0.85

Calls 3

fileStatusTagFunction · 0.85
formatTaskIDFunction · 0.85
formatChangeSummaryFunction · 0.85

Tested by

no test coverage detected