amend sys.HandleSigKill

This commit is contained in:
Mahdi Abu Yasmine 2023-11-07 00:10:32 +01:00
parent 2d804b3e59
commit 8086f2df95

View File

@ -122,10 +122,8 @@ func HandleSigKill(done chan os.Signal) {
signal.Notify(done, syscall.SIGINT, syscall.SIGTERM) signal.Notify(done, syscall.SIGINT, syscall.SIGTERM)
go func() { go func() {
<-done // Will block here until user hits ctrl+c <-done // Will block here until user hits ctrl+c
cmd := exec.Command("tput", "cnorm") RunCmd(exec.Command("tput", "cnorm"))
RunCmd(cmd) RunCmd(exec.Command("tput", "-x", "clear"))
cmd = exec.Command("tput", "-x", "clear")
RunCmd(cmd)
os.Exit(0) os.Exit(0)
}() }()
} }