code: func IsExecutable(path string) bool {
  	d, err := os.Stat(path)
  	if err == nil {
  		m := d.Mode()
  		return !m.IsDir() && m&0111 != 0
  	}
  	return false
  }
docs: // IsExecutable checks if the given path points to an executable file by
  // checking the executable bit. Inspired by os.exec.LookPath()