diff options
author | stk <stk@ableton.com> | 2023-01-25 21:36:43 +0100 |
---|---|---|
committer | stk <stk@ableton.com> | 2023-01-26 10:30:05 +0100 |
commit | fc38e3b54d2327feee6ef30a78463238eb7554a4 (patch) | |
tree | 98ca6312380b93ca57b2efdfaa0d74afdc6dbb1f /pkg/commands/patch | |
parent | 93d845cb015696863033ee3adf1b813b525698d0 (diff) |
Don't omit final line feed when copying diff lines to clipboard
Diffstat (limited to 'pkg/commands/patch')
-rw-r--r-- | pkg/commands/patch/patch_parser.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/commands/patch/patch_parser.go b/pkg/commands/patch/patch_parser.go index b57242c67..1fd3c107a 100644 --- a/pkg/commands/patch/patch_parser.go +++ b/pkg/commands/patch/patch_parser.go @@ -210,10 +210,10 @@ func (p *PatchParser) RenderLinesPlain(firstLineIndex, lastLineIndex int) string func renderLinesPlain(lines []*PatchLine) string { renderedLines := slices.Map(lines, func(line *PatchLine) string { - return line.Content + return line.Content + "\n" }) - return strings.Join(renderedLines, "\n") + return strings.Join(renderedLines, "") } // GetNextStageableLineIndex takes a line index and returns the line index of the next stageable line |