mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-05-12 12:55:47 +02:00
strip NUL bytes instead of replacing with space
This commit is contained in:
parent
3375cc1b3d
commit
e3f21f0588
5 changed files with 9 additions and 9 deletions
6
vendor/github.com/jesseduffield/gocui/view.go
generated
vendored
6
vendor/github.com/jesseduffield/gocui/view.go
generated
vendored
|
@ -1080,7 +1080,7 @@ func (v *View) BufferLines() []string {
|
|||
lines := make([]string, len(v.lines))
|
||||
for i, l := range v.lines {
|
||||
str := lineType(l).String()
|
||||
str = strings.Replace(str, "\x00", " ", -1)
|
||||
str = strings.Replace(str, "\x00", "", -1)
|
||||
lines[i] = str
|
||||
}
|
||||
return lines
|
||||
|
@ -1098,7 +1098,7 @@ func (v *View) ViewBufferLines() []string {
|
|||
lines := make([]string, len(v.viewLines))
|
||||
for i, l := range v.viewLines {
|
||||
str := lineType(l.line).String()
|
||||
str = strings.Replace(str, "\x00", " ", -1)
|
||||
str = strings.Replace(str, "\x00", "", -1)
|
||||
lines[i] = str
|
||||
}
|
||||
return lines
|
||||
|
@ -1274,7 +1274,7 @@ func (v *View) SelectedLine() string {
|
|||
}
|
||||
line := v.lines[v.SelectedLineIdx()]
|
||||
str := lineType(line).String()
|
||||
return strings.Replace(str, "\x00", " ", -1)
|
||||
return strings.Replace(str, "\x00", "", -1)
|
||||
}
|
||||
|
||||
func (v *View) SelectedPoint() (int, int) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue