diff options
| author | Lukasz Kasprzak <lukas@labunix.xyz> | 2026-09-14 21:36:31 +0200 |
|---|---|---|
| committer | Lukasz Kasprzak <lukas@labunix.xyz> | 2026-09-14 21:36:31 +0200 |
| commit | d53c83e2fe6f1ecef006f116095fa8d1d18f3a7d (patch) | |
| tree | 91f850a794c89eff5221dbbb5fcdb1b9b4632532 /cmd/krino/undo.go | |
| parent | 93cf0729ec7cf3129de0808cbcc3403b86d86fff (diff) | |
| download | krino-d53c83e2fe6f1ecef006f116095fa8d1d18f3a7d.tar.gz krino-d53c83e2fe6f1ecef006f116095fa8d1d18f3a7d.zip | |
plan 9: errors, explain traces, JSON and log fields never reach the terminal raw
Diffstat (limited to 'cmd/krino/undo.go')
| -rw-r--r-- | cmd/krino/undo.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cmd/krino/undo.go b/cmd/krino/undo.go index c942ae1..4c85185 100644 --- a/cmd/krino/undo.go +++ b/cmd/krino/undo.go @@ -146,7 +146,7 @@ func cmdUndo(g *globals, args []string, stdout, stderr io.Writer) int { }() } - fmt.Fprintln(stdout, p.bold("krino: undo "+up.Run)) + fmt.Fprintln(stdout, p.bold("krino: undo "+display(up.Run))) var buf bytes.Buffer printUndoPlan(&buf, up) text := colourRefused(buf.String(), p) @@ -465,7 +465,7 @@ const undoStepWidth = len("undo-displace") // no root-relative form to render here the way actionCell has. func undoActionCell(s engine.UndoStep) string { if s.Refused != "" { - return padCell(s.Action, undoStepWidth) + " refused: " + display(s.Refused) + return padCell(display(s.Action), undoStepWidth) + " refused: " + display(s.Refused) } switch s.Action { case "undo-mkdir": @@ -473,7 +473,7 @@ func undoActionCell(s engine.UndoStep) string { case "undo-copy": return padCell(s.Action, undoStepWidth) + " " + display(xdg.Abbrev(s.Src)) + " → trash" } - return padCell(s.Action, undoStepWidth) + " → " + display(xdg.Abbrev(s.Dst)) + return padCell(display(s.Action), undoStepWidth) + " → " + display(xdg.Abbrev(s.Dst)) } // printUndoPlan renders an undo plan the way krino undo shows it, below the |
