Skip to content

Commit 659a602

Browse files
committed
added code example for static data
1 parent d34df7a commit 659a602

16 files changed

Lines changed: 453 additions & 1 deletion

File tree

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ All modules require **Java 11** to compile and run.
1212

1313
# Building with Gradle
1414

15-
The build is configured so that you can build all modules at once or each module separately.
15+
Modules should be as independent as possible. There are groups of modules that only work together, but other than that, a module should have its own build.
16+
17+
See [build-all.sh](build-all.sh) for all builds that are run in the CI pipeline.
1618

1719
## Building all Modules at Once
1820

build-all.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,9 @@ cd patterns && {
2424
./gradlew clean build --info
2525
cd ../../
2626
}
27+
28+
cd spring-boot/static && {
29+
chmod +x gradlew
30+
./gradlew clean build --info
31+
cd ../../
32+
}

gradlew

100644100755
File mode changed.

spring-boot/static/.gitignore

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
HELP.md
2+
.gradle
3+
build/
4+
!gradle/wrapper/gradle-wrapper.jar
5+
!**/src/main/**
6+
!**/src/test/**
7+
8+
### STS ###
9+
.apt_generated
10+
.classpath
11+
.factorypath
12+
.project
13+
.settings
14+
.springBeans
15+
.sts4-cache
16+
17+
### IntelliJ IDEA ###
18+
.idea
19+
*.iws
20+
*.iml
21+
*.ipr
22+
out/
23+
24+
### NetBeans ###
25+
/nbproject/private/
26+
/nbbuild/
27+
/dist/
28+
/nbdist/
29+
/.nb-gradle/
30+
31+
### VS Code ###
32+
.vscode/

spring-boot/static/build.gradle

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
plugins {
2+
id 'org.springframework.boot' version '2.2.1.RELEASE'
3+
id 'io.spring.dependency-management' version '1.0.8.RELEASE'
4+
id 'java'
5+
}
6+
7+
group = 'io.reflectoring'
8+
version = '0.0.1-SNAPSHOT'
9+
sourceCompatibility = '11'
10+
11+
repositories {
12+
mavenCentral()
13+
}
14+
15+
dependencies {
16+
implementation 'org.springframework.boot:spring-boot-starter'
17+
testImplementation('org.springframework.boot:spring-boot-starter-test') {
18+
exclude group: 'org.junit.vintage', module: 'junit-vintage-engine'
19+
}
20+
}
21+
22+
test {
23+
useJUnitPlatform()
24+
}
25+
26+
bootRun{
27+
jvmArgs = ["-Dspring.config.location=./,./quotes.yml"]
28+
}
54.9 KB
Binary file not shown.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
distributionBase=GRADLE_USER_HOME
2+
distributionPath=wrapper/dists
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-bin.zip
4+
zipStoreBase=GRADLE_USER_HOME
5+
zipStorePath=wrapper/dists

spring-boot/static/gradlew

Lines changed: 172 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

spring-boot/static/gradlew.bat

Lines changed: 84 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

spring-boot/static/quotes.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
static:
2+
quotes:
3+
- text: "A clever person solves a problem. A wise person avoids it."
4+
author: "Albert Einstein"
5+
- text: "Adding manpower to a late software project makes it later."
6+
author: "Fred Brooks"

0 commit comments

Comments
 (0)