reads the product of makeSymlink on Windows
(path string)
| 736 | |
| 737 | // reads the product of makeSymlink on Windows |
| 738 | func readPathFromFile(path string) (string, error) { |
| 739 | f, err := os.Open(path) |
| 740 | if err != nil { |
| 741 | return "", err |
| 742 | } |
| 743 | defer f.Close() |
| 744 | b := make([]byte, 1024) |
| 745 | n, err := f.Read(b) |
| 746 | return strings.TrimSpace(string(b[:n])), err |
| 747 | } |
| 748 | |
| 749 | func isBinExtension(client *http.Client, repo ghrepo.Interface) (isBin bool, err error) { |
| 750 | var r *release |