Does anyone know how I could hardcode `JDK_JAVA_OP...
# general
p
Does anyone know how I could hardcode
JDK_JAVA_OPTIONS="--add-opens=java.base/java.nio=org.apache.arrow.memory.core,ALL-UNNAMED"
into the execution of a jar? The pants.toml config includes internal pants java executions where this breaks them
b
I'm not familiar with the specifics of the JDK backends... but... Are you looking to hardcode this for CLI executions of the jar like
pants run path/to/some:jar
, or for some other circumstance?
p
mostly for pants run; I don't think it is possible to do it more generally, but I'm also not super familiar with jar packaging
b
Ah okay. If it’s for
run
then a potential option might be seeing an alias https://www.pantsbuild.org/stable/reference/subsystems/cli For instance, an alias like
run-jar = run --jdk-java-options=…
would allow
pants run-jar path/to:jar