It would be a great thing if you could synchronize commandLine args and webharvest.properties. It is a bit painful to have the settings in a file for the development gui and to pass all settings to command line as arguments in batch mode.
I have completely rewritten the CommandLine class. CommandLine is now using the very same settings the GUI is using (overridden by command line args). Parameters syntax is also more common sense now, since I have introduced apache commons cli. I have also changed everything from properties to jconfig files. Please check this patch.
I have now made all the settings suff more "guicy". Check out that I have moved all the settings to core. When someone develops plugins it is much more easy to get the right classpath dependecy otherwise you always have a cyclic dependecy!
Now not only any setting can be synced between console and gui mode, you also can get any runtime setting in a plugin by just injecting the runtime settings
@Inject
RuntimeSettings settings;
It is still not perfect but much more comfortable in usage!
I have completely rewritten the CommandLine class. CommandLine is now using the very same settings the GUI is using (overridden by command line args). Parameters syntax is also more common sense now, since I have introduced apache commons cli. I have also changed everything from properties to jconfig files. Please check this patch.
I have now made all the settings suff more "guicy". Check out that I have moved all the settings to core. When someone develops plugins it is much more easy to get the right classpath dependecy otherwise you always have a cyclic dependecy!
Anyway check out:
/webharvest-core/src/main/java/org/webharvest/RuntimeSettings.java
/webharvest-core/src/main/java/org/webharvest/RuntimeSettingsProvider.java
/webharvest-core/src/main/java/org/webharvest/ioc/ScraperModule.java
/webharvest-ide/src/main/java/org/webharvest/ApplicationInfo.java
/webharvest-ide/src/main/java/org/webharvest/CommandLine.java
/webharvest-ide/src/main/java/org/webharvest/gui/Ide.java
/webharvest-ide/src/main/java/org/webharvest/gui/Settings.java
Now not only any setting can be synced between console and gui mode, you also can get any runtime setting in a plugin by just injecting the runtime settings
@Inject
RuntimeSettings settings;
It is still not perfect but much more comfortable in usage!