From 9ef16c1bf2bfc1e00163b461779383c809efff9f Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Mon, 3 Mar 2025 03:45:36 -0600 Subject: better tree init() --- structs.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'structs.go') diff --git a/structs.go b/structs.go index c85e859..8b9541c 100644 --- a/structs.go +++ b/structs.go @@ -25,7 +25,6 @@ import ( ) var initOnce sync.Once // run initPlugin() only once -var outf *os.File // hacks for capturing stdout // It's probably a terrible idea to call this 'me' // 2025 note: doesn't seem terrible to call this 'me' anymore. notsure. @@ -87,6 +86,7 @@ type config struct { starttime time.Time // checks how long it takes on startup winchW int // used to detect SIGWINCH winchH int // used to detect SIGWINCH + outf *os.File // hacks for capturing stdout } // stuff controlling how the mouse works @@ -112,6 +112,7 @@ type stdout struct { outputOnTop bool // is the STDOUT window on top? outputOffscreen bool // is the STDOUT window offscreen? startOnscreen bool // start the output window onscreen? + disable bool // disable the stdout window. do not change os.Stdout & os.Stderr lastW int // the last 'w' location (used to move from offscreen to onscreen) lastH int // the last 'h' location (used to move from offscreen to onscreen) // mouseOffsetW int // the current 'w' offset -- cgit v1.2.3