INNER CODE UNIT · Go

version

shenwei356/rush · helper.go:51

		version = items[len(items)-2]
	} else {
		version = items[len(items)-1]
	}
	if version == "v"+VERSION {
		fmt.Printf("You are using the latest version of %s\n", app)
	} else {
		fmt.Printf("New version available: %s %s at %s\n", app, version, resp.Request.URL.String())
	}
}

func exists(path string) (bool, error) {
	_, err := os.Stat(path)
	if err == nil {
		return true, nil
	}
	if os.IsNotExist(err) {
		return false, nil

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…