cbeust/jcommander — pull request #123 by SJrX (2012-07-03 03:51:04+00:00)
Title: @ParameterFile support

Hello as per this thread (https://groups.google.com/forum/?fromgroups#!topic/jcommander/dE6UyojYiVE) I have implemented support for configuration files. This does not support variable arguments currently, as the method I use to read configuration files is via a Properties object, and it didn't occur to me that I can't have multiple keys.

In short you specify things as

@ParameterFile
@Parameter(names="--conf")
File configurationFile;

I did add a Test class, originally I tried with TestNG but because of a few problems A) I couldn't run TestNG in debug mode in Eclipse it would just lock up, and B) It seemed like I had to do something with Maven to actually get the updated files to be tested against, and I didn't know how to do this.

There is still more work to do be done (multiple arity arguments, and a few more tests), but I wanted to get some feedback in the interim.