INNER CODE UNIT · Go
isStdin
shenwei356/rush · helper.go:35
func isStdin(file string) bool {
return file == "-"
}
func checkVersion() {
app := "rush"
fmt.Printf("%s v%s\n", app, VERSION)
fmt.Println("\nChecking new version...")
resp, err := http.Get(fmt.Sprintf("https://github.com/shenwei356/%s/releases/latest", app))
if err != nil {
checkError(fmt.Errorf("Network error"))
}
items := strings.Split(resp.Request.URL.String(), "/")
var version string
if items[len(items)-1] == "" {
version = items[len(items)-2]
} else {