asdf/internal/exec/exec.go

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

13 lines
349 B
Go
Raw Normal View History

// Package exec handles replacing the asdf go process with
package exec
import (
"syscall"
)
// Exec invokes syscall.Exec to exec an executable. Requires an absolute path to
// executable.
func Exec(executablePath string, args []string, env []string) error {
return syscall.Exec(executablePath, append([]string{executablePath}, args...), env)
}