Maven supports the MAVEN_ARGS
environment variable.
I want to add the argument -Dsomeparam="-X -A"
and run Maven.
But when I do this, it’s clear it’s trying to split the argument via spaces and fails:
Unable to parse command line options: Unrecognized option: -A"
Which means the quoting is not correct.
Simple reproducer:
#!/bin/bash
MAVEN_ARGS="-Dsomeparam="-X -A"" mvn --version