robherley/snips.sh

Gracefully end session for TUI

SrRyan opened this issue · 0 comments

SrRyan commented

If your session ends while your away or not looking, your terminal session becomes stuck and you can't leave the TUI. It would be best if it would gracefully exit the TUI before ending the session if it's expired so that the user isn't stuck.

Related code block

case <-timer.C:
log.Warn().Msg("max session duration reached")
program.Quit()
return

Reproduce:

  1. Open new session
  2. wait till max time till session expires
  3. attempt to do a command or navigate tui