Skip to content

Commit

Permalink
add missing python bin to path
Browse files Browse the repository at this point in the history
  • Loading branch information
cpunion committed Nov 21, 2024
1 parent 401c360 commit a1c9ae0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions internal/env/env.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ func GetPythonRoot(projectPath string) string {

// GetPythonBinDir returns the Python binary directory path relative to project path
func GetPythonBinDir(projectPath string) string {
if runtime.GOOS == "windows" {
return filepath.Join(GetPythonRoot(projectPath))
}
return filepath.Join(GetPythonRoot(projectPath), "bin")
}

Expand Down Expand Up @@ -93,6 +96,7 @@ func SetBuildEnv(projectPath string) {
}
path := os.Getenv("PATH")
path = GetGoBinDir(absPath) + pathSeparator() + path
path = GetPythonBinDir(absPath) + pathSeparator() + path

Check warning on line 99 in internal/env/env.go

View check run for this annotation

Codecov / codecov/patch

internal/env/env.go#L99

Added line #L99 was not covered by tests
if runtime.GOOS == "windows" {
path = GetMingwRoot(absPath) + pathSeparator() + path
path = GetTinyPkgConfigDir(absPath) + pathSeparator() + path
Expand Down

0 comments on commit a1c9ae0

Please sign in to comment.