code: func (r *Runner) deletePid() error {
  	path := config.StringVal(r.config.PidFile)
  	if path == "" {
  		return nil
  	}
  
  	log.Printf("[DEBUG] removing pid file at %q", path)
  
  	stat, err := os.Stat(path)
  	if err != nil {
  		return fmt.Errorf("runner: could not remove pid file: %s", err)
  	}
  	if stat.IsDir() {
  		return fmt.Errorf("runner: specified pid file path is directory")
  	}
  
  	err = os.Remove(path)
  	if err != nil {
  		return fmt.Errorf("runner: could not remove pid file: %s", err)
  	}
  	return nil
  }
docs: // deletePid is used to remove the PID on exit.