use of de.undercouch.underline.StandardInputReader in project georocket by georocket.
the class GeoRocketCli method main.
/**
* Run the GeoRocket command-line interface
* @param args the command line arguments
* @throws IOException if a stream could not be read
*/
public static void main(String[] args) throws IOException {
// start CLI
GeoRocketCli cli = new GeoRocketCli();
cli.setup();
try {
PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out, StandardCharsets.UTF_8));
cli.setEndHandler(exitCode -> {
out.flush();
System.exit(exitCode);
});
cli.run(args, new StandardInputReader(), out);
} catch (OptionParserException e) {
cli.error(e.getMessage());
System.exit(1);
}
}
Aggregations