BaseXdb/basex — pull request #457 by charles-dyfis-net (2012-03-29 23:28:50+00:00)
Title: Allow arbitrary JVM arguments to be passed to wrapper / startup scripts

Launching basex commands with `-X ""` will add `` to the argument list passed to the JVM on invocation. This allows arbitrary commands -- memory tuning, debug / JMX arguments, Java properties, etc -- to be added to startup without requiring that the user edit the startup script itself.

Multiple `-X ""` pairs can be used.

This implementation uses bash arrays to store the constructed argument list; unlike storing the desired argument list in a single variable (and passing this variable unquoted to be string-split by the shell), this approach allows arguments containing whitespace (or other values found in the global `$IFS` variable) to be included in JVM parameters.