Skip to content
This repository has been archived by the owner on Dec 10, 2020. It is now read-only.

Commit

Permalink
Update jdk paths reference in jvm_projects documentation
Browse files Browse the repository at this point in the history
We got a bug report about the jvm project setup having the wrong info in it. This updates the example stanzas and wording around them.

Testing Done:
Posted up at http://pantsbuild.github.io/staging/nhoward-test following publishing docs.

Bugs closed: 3509, 3516

Reviewed at https://rbcommons.com/s/twitter/r/3942/

closes pantsbuild#3509, closes pantsbuild#3516
  • Loading branch information
baroquebobcat committed Jun 2, 2016
1 parent cb1c39f commit 1464c0a
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions examples/src/java/org/pantsbuild/example/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -215,11 +215,12 @@ compilation for Java and Scala.
Java7 vs Java6, Which Java
--------------------------

Pants first looks through any jdks specified by the jdk_paths map in pants.ini, eg:
Pants first looks through any JDKs specified by the `paths` map in pants.ini's jvm-distributions
section, eg:

:::ini
[jvm]
jdk_paths = {
[jvm-distributions]
paths = {
'macos': [
'/Library/Java/JavaVirtualMachines/jdk1.7.0_79.jdk',
'/Library/Java/JavaVirtualMachines/jdk1.8.0_45.jdk',
Expand All @@ -229,9 +230,9 @@ Pants first looks through any jdks specified by the jdk_paths map in pants.ini,
]
}

If no jvms are found there, Pants uses the first java it finds in `JDK_HOME`, `JAVA_HOME`,
or `PATH`. If no jdk_paths are set, you can specify a specific java version for just one
pants invocation:
If no JVMs are found there, Pants uses the first Java it finds in `JDK_HOME`, `JAVA_HOME`,
or `PATH`. If no `paths` are specified in pants.ini, you can use JDK_HOME to set the Java version
for just one pants invocation:

:::bash
$ JDK_HOME=/usr/lib/jvm/java-1.7.0-openjdk-amd64 ./pants ...
Expand Down

0 comments on commit 1464c0a

Please sign in to comment.