Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add default values to each yo-rc.json property #226

Merged
merged 1 commit into from
Sep 2, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,23 @@ public YoRC deserialize(JsonParser jp, DeserializationContext ctxt) throws IOExc
JsonNode node = jp.getCodec().readTree(jp);

String serverPort = getDefaultIfNull(node.get("serverPort"), "8080");
String authenticationType = node.get("authenticationType").asText();
String authenticationType = getDefaultIfNull(node.get("authenticationType"), "");
String cacheProvider = getDefaultIfNull(node.get("cacheProvider"), "no");
boolean enableHibernateCache = getDefaultIfNull(node.get("enableHibernateCache"), false);
boolean webSocket = node.get("websocket").asBoolean();
String databaseType = node.get("databaseType").asText();
String devDatabaseType = node.get("devDatabaseType").asText();
String prodDatabaseType = node.get("prodDatabaseType").asText();
boolean webSocket = getDefaultIfNull(node.get("websocket"), false);
String databaseType = getDefaultIfNull(node.get("databaseType"), "");
String devDatabaseType = getDefaultIfNull(node.get("devDatabaseType"), "");
String prodDatabaseType = getDefaultIfNull(node.get("prodDatabaseType"), "");
boolean searchEngine = getDefaultIfNull(node.get("searchEngine"), false);
boolean messageBroker = getDefaultIfNull(node.get("messageBroker"), false);
boolean serviceDiscoveryType = getDefaultIfNull(node.get("serviceDiscoveryType"), false);
String buildTool = node.get("buildTool").asText();
String buildTool = getDefaultIfNull(node.get("buildTool"), "");
boolean enableSwaggerCodegen = getDefaultIfNull(node.get("enableSwaggerCodegen"), false);
String clientFramework = getDefaultIfNull(node.get("clientFramework"), "none");
boolean useSass = getDefaultIfNull(node.get("useSass"), false);
String clientPackageManager = node.get("clientPackageManager").asText();
String applicationType = node.get("applicationType").asText();
boolean enableTranslation = node.get("enableTranslation").asBoolean();
String clientPackageManager = getDefaultIfNull(node.get("clientPackageManager"), "");
String applicationType = getDefaultIfNull(node.get("applicationType"), "");
boolean enableTranslation = getDefaultIfNull(node.get("enableTranslation"), false);
String nativeLanguage = getDefaultIfNull(node.get("nativeLanguage"), "");
boolean hasProtractor = false;
boolean hasGatling = false;
Expand Down