From 456aeda605d9e253f44d8598205fe114209836e1 Mon Sep 17 00:00:00 2001 From: Aliaksandr Valialkin Date: Tue, 1 Oct 2024 21:46:33 +0200 Subject: [PATCH] app/vlogscli: preserve `less` output This simplifies logs' investigation, since it allows copying some text from the previous query output --- app/vlogscli/less_wrapper.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/vlogscli/less_wrapper.go b/app/vlogscli/less_wrapper.go index 04ba3bd2a..d7a0d5637 100644 --- a/app/vlogscli/less_wrapper.go +++ b/app/vlogscli/less_wrapper.go @@ -48,7 +48,7 @@ func readWithLess(r io.Reader) error { if err != nil { return fmt.Errorf("cannot find 'less' command: %w", err) } - p, err := os.StartProcess(path, []string{"less", "-F"}, &os.ProcAttr{ + p, err := os.StartProcess(path, []string{"less", "-F", "-X"}, &os.ProcAttr{ Env: append(os.Environ(), "LESSCHARSET=utf-8"), Files: []*os.File{pr, os.Stdout, os.Stderr}, })