2016-08-09 17:07:21 +00:00
|
|
|
// +build windows
|
|
|
|
|
|
|
|
package adb
|
|
|
|
|
|
|
|
import (
|
|
|
|
"errors"
|
|
|
|
"strings"
|
|
|
|
)
|
|
|
|
|
2016-08-27 01:17:20 +00:00
|
|
|
func isExecutableOnPlatform(path string) error {
|
|
|
|
if strings.HasSuffix(path, ".exe") || strings.HasSuffix(path, ".cmd") ||
|
|
|
|
strings.HasSuffix(path, ".bat") {
|
2016-08-09 17:07:21 +00:00
|
|
|
return nil
|
|
|
|
}
|
|
|
|
return errors.New("not an executable")
|
|
|
|
}
|