Closed ingokegel closed 8 years ago
@ingokegel can more than one --var-file
be specified? this changes all variables to be passed by file ref, but what if you already had a variable file want to use it + others defined from build execution?
If it supports more than one, then we can have one being user-managed, and another generated for any variables configured.
can more than one
--var-file
be specified
Currently not, this will only be possible in install4j 6.1. However, what is supported since 4.1.5 is the ability to use a single --var-file
argument with multiple files separated by semicolons. That's what the patch uses, so there will be no difference with respect to the previous behavior.
Will tidy up a few things and merge this in the next day or so.
Thanks!
@ingokegel I've merged a similar version. I exposed the variable file for mvn config, and leaving it in build output directory instead of auto-deleting it for debugging purposes. Mvn plugins that magically write out tmp files then delete them can be very hard to debug when/if things go south.
If folks really want to have this magically vanish I can add a flag to enable automatic deletion (or retention depending on which way the boolean flies).
@jdillon Thank you! Keeping the file for debugging purposes sounds like a good idea.
@ingokegel snapshots are deployed, let me know if you run into any problems, otherwise I can stage a release if you have folks itching to use this.
@jdillon It's not really urgent, install4j 6.1 is still two weeks away and then people first have to start using ultra-long variable values with the new features before it becomes a problem.
The maximum length of the command line can be quite low (8192 on Windows). In the upcoming install4j 6.1 release it will be possible to pass lists of files in compiler variables that can be added to the distribution tree or launcher classpaths. To avoid problems with truncated command lines, this patch passes compiler variables in a temporary file that is deleted after the execution. This change is backwards-compatible with install4j versions down to 4.1.5.
Also, the install4j runtime is now available in a repository. I've added it to the top-level pom, please change as appropriate.