Skip to content

Commit

Permalink
Add BAZELISK_NOJDK support to Bazelisk Go
Browse files Browse the repository at this point in the history
  • Loading branch information
sf-jbazuzi committed Jan 17, 2024
1 parent bed91ec commit e4bf9f5
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion platforms/platforms.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,15 @@ func DetermineOperatingSystem() (string, error) {
}

// DetermineBazelFilename returns the correct file name of a local Bazel binary.
func DetermineBazelFilename(version string, includeSuffix bool, config_ config.Config) (string, error) {
func DetermineBazelFilename(version string, includeSuffix bool, config config.Config) (string, error) {
flavor := "bazel"

bazeliskNojdk := config.Get("BAZELISK_NOJDK")

if len(bazeliskNojdk) != 0 && bazeliskNojdk != "0" {
flavor = "bazel_nojdk"
}

osName, err := DetermineOperatingSystem()
if err != nil {
return "", err
Expand Down

0 comments on commit e4bf9f5

Please sign in to comment.