implemented event and req
This commit is contained in:
20
pkg/utils/interrupt/restart_darwin.go
Normal file
20
pkg/utils/interrupt/restart_darwin.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package interrupt
|
||||
|
||||
func Restart() {
|
||||
// TODO: test this thing actually works!
|
||||
// log.D.Ln("doing windows restart")
|
||||
// // procAttr := new(os.ProcAttr)
|
||||
// // procAttr.Files = []*os.File{os.Stdin, os.Stdout, os.Stderr}
|
||||
// // os.StartProcess(os.Args[0], os.Args[1:], procAttr)
|
||||
// var s []string
|
||||
// // s = []string{"cmd.exe", "/C", "start"}
|
||||
// s = append(s, os.Args[0])
|
||||
// // s = append(s, "--delaystart")
|
||||
// s = append(s, os.Args[1:]...)
|
||||
// cmd := exec.Command(s[0], s[1:]...)
|
||||
// log.D.Ln("windows restart done")
|
||||
// if err := cmd.Start(); log.Fail(err) {
|
||||
// }
|
||||
// // select{}
|
||||
// os.Exit(0)
|
||||
}
|
||||
Reference in New Issue
Block a user