19 lines
287 B
Go
19 lines
287 B
Go
|
package internal
|
||
|
|
||
|
import (
|
||
|
`runtime`
|
||
|
)
|
||
|
|
||
|
// GetPathEnvName gets the OS-specific path environment variable name.
|
||
|
func GetPathEnvName() (envVarName string) {
|
||
|
|
||
|
var ok bool
|
||
|
|
||
|
if envVarName, ok = pathEnvVarName[runtime.GOOS]; !ok {
|
||
|
// *NIX/the default.
|
||
|
envVarName = "PATH"
|
||
|
}
|
||
|
|
||
|
return
|
||
|
}
|