9fans.net/go@v0.0.5/acme/Watch/sig_generic.go (about)

     1  // Copyright 2020 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  // +build !linux,!darwin,!freebsd,!netbsd,!openbsd,!solaris
     6  
     7  package main
     8  
     9  import (
    10  	"os"
    11  	"os/exec"
    12  	"time"
    13  )
    14  
    15  func isolate(cmd *exec.Cmd) {
    16  }
    17  
    18  func quit(cmd *exec.Cmd) {
    19  }
    20  
    21  func kill(cmd *exec.Cmd) {
    22  	cmd.Process.Signal(os.Interrupt)
    23  	time.Sleep(100 * time.Millisecond)
    24  	cmd.Process.Kill()
    25  }