goadb/adb/executable_win.go
2020-07-13 14:18:10 +08:00

17 lines
282 B
Go

// +build windows
package adb
import (
"errors"
"strings"
)
func isExecutableOnPlatform(path string) error {
if strings.HasSuffix(path, ".exe") || strings.HasSuffix(path, ".cmd") ||
strings.HasSuffix(path, ".bat") {
return nil
}
return errors.New("not an executable")
}