Просмотр исходного кода

stop on TERM signal as well.

which is the proper signal, I think, and it's the one sublime/python
seems to send to subprocesses.
Lucas Stadler лет назад: 11
Родитель
Сommit
b70d532397
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      go/qst.go

+ 1 - 1
go/qst.go

85
	go runCmd(file, runner)
85
	go runCmd(file, runner)
86
86
87
	c := make(chan os.Signal, 1)
87
	c := make(chan os.Signal, 1)
88
	signal.Notify(c, os.Interrupt, os.Kill)
88
	signal.Notify(c, os.Interrupt, os.Kill, syscall.SIGTERM)
89
	s := <-c
89
	s := <-c
90
	log.Printf("got signal: %s, exiting...", s)
90
	log.Printf("got signal: %s, exiting...", s)
91
	runner.Stop()
91
	runner.Stop()