public static boolean isMacOSX = false;
public static boolean isLinux = false;
public static void main(String[] args) throws IOException{
arguments = new Arguments(args);
Json json = new Json();
json.setOutputType(OutputType.json);
determineOS();
System.out.println("Jar Wrapper Version " + version);
System.out.println("*********");
/*
BundlerConfig config = new BundlerConfig();
config.defaults();
String configFile = json.prettyPrint(config);
saveConfigFile(configFile);
*/
System.out.print("Loading config file ... ");
File configFile;
if(arguments.has("-config")){
configFile = new File(arguments.get("-config"));
}
else {
configFile = new File("config/config.json");
}
if(!configFile.exists()){
System.out.println("Can't find the supplied config file, or the default file.");
System.exit(0);
}
else {
String configContent = readFile(configFile);
config = json.fromJson(BundlerConfig.class, configContent);
}
if(config == null){
System.out.println("Something went wrong while loading the config file. Abort.");
System.exit(0);