The first number is the count of modules that contain a package that imports this one.
The module count is a better indicator of popularity than the package count.
A module with 100 importing packages is counted only once instead of 100 times,
reflecting the fact that the choice to use the package was likely made only once,
not 100 times.
A '?' means that the value hasn't been computed yet.
CheckWritable verifies that the running process can replace the binary at
targetPath by probing the parent directory. os.Rename only requires write
permission on the parent directory, not on the target file itself.
ResolveExecutable returns the path of the current binary with symlinks
resolved. Callers use the resolved path consistently for permission checks,
user-facing messages, and the rename target.
SelfReplace downloads the release asset for the given tag and replaces the
binary at targetPath in place. Only supported on linux and darwin.
Callers should resolve symlinks before invoking so the rename targets the
real binary.
const (
// MethodBinary is a standalone binary (install.sh, manual download, or unknown). MethodBinary Method = iota// MethodBrew is a Homebrew cask install. MethodBrew
// MethodGoInstall is a `go install` install. MethodGoInstall
)