Skip to content

Commit f57f8d1

Browse files
committed
add createdDate, add default image name, update jgitver config
1 parent bd4d336 commit f57f8d1

File tree

6 files changed

+25
-15
lines changed

6 files changed

+25
-15
lines changed

.mvn/jgitver.config.xml

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,15 @@
22
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
33
xsi:schemaLocation="http://jgitver.github.io/maven/configuration/1.1.0 https://jgitver.github.io/maven/configuration/jgitver-configuration-v1_1_0.xsd">
44
<strategy>CONFIGURABLE</strategy>
5-
<policy>NEAREST</policy>
5+
<policy>MAX</policy>
66
<autoIncrementPatch>true</autoIncrementPatch>
7-
<useCommitDistance>false</useCommitDistance>
8-
<useDirty>false</useDirty>
7+
<useDirty>true</useDirty>
98
<useGitCommitId>false</useGitCommitId>
10-
<useSnapshot>false</useSnapshot> <!-- use -SNAPSHOT in CONFIGURABLE strategy -->
11-
<gitCommitIdLength>8</gitCommitIdLength> <!-- between [8,40] -->
12-
<nonQualifierBranches>main</nonQualifierBranches> <!-- comma separated, example "master,integration" -->
13-
<useDefaultBranchingPolicy>true</useDefaultBranchingPolicy> <!-- uses jgitver#BranchingPolicy#DEFAULT_FALLBACK as fallback branch policy-->
14-
</configuration>
9+
<useSnapshot>true</useSnapshot>
10+
<gitCommitIdLength>8</gitCommitIdLength>
11+
<nonQualifierBranches>main</nonQualifierBranches>
12+
<useDefaultBranchingPolicy>true</useDefaultBranchingPolicy>
13+
<exclusions> <!-- Optional list of directory path -->
14+
<exclusion>.m2</exclusion> <!-- relative path from project root directory -->
15+
</exclusions>
16+
</configuration>

.mvn/wrapper/maven-wrapper.jar

3.73 KB
Binary file not shown.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.4/apache-maven-3.8.4-bin.zip
2-
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar
1+
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.2/apache-maven-3.9.2-bin.zip
2+
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar

pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@
55
<parent>
66
<groupId>org.springframework.boot</groupId>
77
<artifactId>spring-boot-starter-parent</artifactId>
8-
<version>3.1.0</version>
8+
<version>3.1.1</version>
99
<relativePath></relativePath>
1010
</parent>
1111
<groupId>dev.dashaun.shell.initializr</groupId>
1212
<artifactId>plusplus</artifactId>
1313
<version>0</version>
1414
<name>${project.groupId}:${project.artifactId}</name>
1515
<properties>
16-
<spring-shell.version>3.1.0</spring-shell.version>
16+
<spring-shell.version>3.1.2</spring-shell.version>
1717
<java.version>17</java.version>
1818
</properties>
1919
<dependencyManagement>

src/main/java/dev/dashaun/shell/initializr/plusplus/MavenExtensionCommands.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,15 +63,17 @@ private String jgitverConfigFile() {
6363
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
6464
xsi:schemaLocation="http://jgitver.github.io/maven/configuration/1.1.0 https://jgitver.github.io/maven/configuration/jgitver-configuration-v1_1_0.xsd">
6565
<strategy>CONFIGURABLE</strategy>
66-
<policy>LATEST</policy>
66+
<policy>MAX</policy>
6767
<autoIncrementPatch>true</autoIncrementPatch>
68-
<useCommitDistance>false</useCommitDistance>
6968
<useDirty>true</useDirty>
7069
<useGitCommitId>false</useGitCommitId>
71-
<useSnapshot>false</useSnapshot>
70+
<useSnapshot>true</useSnapshot>
7271
<gitCommitIdLength>8</gitCommitIdLength>
7372
<nonQualifierBranches>main</nonQualifierBranches>
7473
<useDefaultBranchingPolicy>true</useDefaultBranchingPolicy>
74+
<exclusions> <!-- Optional list of directory path -->
75+
<exclusion>.m2</exclusion> <!-- relative path from project root directory -->
76+
</exclusions>
7577
</configuration>
7678
""";
7779
}

src/main/java/dev/dashaun/shell/initializr/plusplus/models/Plugins.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,8 +146,14 @@ public static Plugin multiArchBuilder() {
146146
Xpp3Dom configuration = new Xpp3Dom("configuration");
147147
Xpp3Dom image = new Xpp3Dom("image");
148148
Xpp3Dom builder = new Xpp3Dom("builder");
149+
Xpp3Dom createdDate = new Xpp3Dom("createdDate");
150+
Xpp3Dom name = new Xpp3Dom("name");
149151
builder.setValue("dashaun/builder:tiny");
152+
createdDate.setValue("now");
153+
name.setValue("${project.groupId}/${project.artifactId}:v${project.version}-${os.detected.arch}");
150154
image.addChild(builder);
155+
image.addChild(createdDate);
156+
image.addChild(name);
151157
configuration.addChild(image);
152158

153159
p.setConfiguration(configuration);

0 commit comments

Comments
 (0)