Fix formatting issues, refactor the `profiles` word in the properties.
This commit is contained in:
parent
0952447f3a
commit
d8a3dd3d71
|
@ -5,8 +5,8 @@ import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||||
|
|
||||||
@SpringBootApplication
|
@SpringBootApplication
|
||||||
public class KebabCasingDemoApplication {
|
public class KebabCasingDemoApplication {
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) {
|
||||||
SpringApplication.run(KebabCasingDemoApplication.class, args);
|
SpringApplication.run(KebabCasingDemoApplication.class, args);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,15 +4,15 @@ import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
|
||||||
@Configuration
|
@Configuration
|
||||||
@ConfigurationProperties(prefix = "profile.profileProperties")
|
@ConfigurationProperties(prefix = "customProperties")
|
||||||
public class MainConfiguration {
|
public class MainConfiguration {
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
public String getName() {
|
public String getName() {
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setName(final String name) {
|
public void setName(final String name) {
|
||||||
this.name = name;
|
this.name = name;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,10 +34,10 @@ not.existing.system.property=${thispropertydoesnotexist}
|
||||||
baeldung.presentation=${HELLO_BAELDUNG}. Java is installed in the folder: ${JAVA_HOME}
|
baeldung.presentation=${HELLO_BAELDUNG}. Java is installed in the folder: ${JAVA_HOME}
|
||||||
#---
|
#---
|
||||||
#camelCasing
|
#camelCasing
|
||||||
#profile.applicationProperties.name="Baeldung"
|
#customProperties.name="Baeldung"
|
||||||
#PascalCasing
|
#PascalCasing
|
||||||
#profile.ApplicationProperties.name="Baeldung"
|
#CustomProperties.name="Baeldung"
|
||||||
#SnakingCasing
|
#SnakingCasing
|
||||||
#profile.application_properties.name="Baeldung"
|
#custom_properties.name="Baeldung"
|
||||||
#KebabCasing
|
#KebabCasing
|
||||||
profile.application-properties.name="Baeldung"
|
custom-properties.name="Baeldung"
|
Loading…
Reference in New Issue