Skip to content

Commit 0c60af8

Browse files
roman-seleznovpivovarit
authored andcommitted
Make projects executable (eugenp#2278)
* Create pom.xml Initial import * First submit * Second submit * Different Types of Bean Injection in Spring * Different Types of Bean Injection in Spring * Added spring-core-di into the main build * Revert "Create pom.xml" This reverts commit 1bdc544. * BAEL-764 Automatic Property Expansion with Spring Boot * BAEL-764 Automatic Property Expansion with Spring Boot * BAEL-764 Automatic Property Expansion with Spring Boot * BAEL-764 Automatic Property Expansion with Spring Boot Make executable jars for property-exp-default project and use mvn exec:java to run property-exp-default project
1 parent 7f5ca78 commit 0c60af8

3 files changed

Lines changed: 33 additions & 0 deletions

File tree

‎spring-boot-property-exp/property-exp-custom/pom.xml‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,15 @@
4040
<include>**/application*.properties</include>
4141
</includes>
4242
</resource>
43+
<resource>
44+
<directory>${basedir}/src/main/resources</directory>
45+
<filtering>true</filtering>
46+
<excludes>
47+
<exclude>**/application*.yml</exclude>
48+
<exclude>**/application*.yaml</exclude>
49+
<exclude>**/application*.properties</exclude>
50+
</excludes>
51+
</resource>
4352
</resources>
4453
<plugins>
4554
<plugin>
@@ -53,6 +62,14 @@
5362
<useDefaultDelimiters>true</useDefaultDelimiters>
5463
</configuration>
5564
</plugin>
65+
<plugin>
66+
<groupId>org.codehaus.mojo</groupId>
67+
<artifactId>exec-maven-plugin</artifactId>
68+
<version>1.6.0</version>
69+
<configuration>
70+
<mainClass>com.baeldung.propertyexpansion.SpringBootPropertyExpansionApp</mainClass>
71+
</configuration>
72+
</plugin>
5673
</plugins>
5774
</build>
5875

‎spring-boot-property-exp/property-exp-default/build.gradle‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ repositories {
2727
mavenCentral()
2828
}
2929

30+
springBoot {
31+
executable = true
32+
}
33+
3034
import org.apache.tools.ant.filters.ReplaceTokens
3135
processResources {
3236
with copySpec {

‎spring-boot-property-exp/property-exp-default/pom.xml‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,4 +30,16 @@
3030
</dependency>
3131
</dependencies>
3232

33+
<build>
34+
<plugins>
35+
<plugin>
36+
<groupId>org.springframework.boot</groupId>
37+
<artifactId>spring-boot-maven-plugin</artifactId>
38+
<configuration>
39+
<executable>true</executable>
40+
</configuration>
41+
</plugin>
42+
</plugins>
43+
</build>
44+
3345
</project>

0 commit comments

Comments
 (0)