Skip to content

Commit 00eee35

Browse files
dariuszkucsmyrick
authored and
smyrick
committed
exclude example app from release profile (ExpediaGroup#275)
Based on nexus-staging-maven-plugin it appears that plugin may not release the artifacts if last module (in our case example app) has it disabled. As I workaround I created defaultBuild profile (active by default) that includes example app but if any other profile is specified (e.g. -P release) then default one will be automatically disabled. This will allow us to release only schema generator module.
1 parent 40e5225 commit 00eee35

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

pom.xml

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@
7070

7171
<modules>
7272
<module>graphql-kotlin-schema-generator</module>
73-
<module>graphql-kotlin-spring-example</module>
7473
</modules>
7574

7675
<properties>
@@ -334,12 +333,6 @@
334333
<!-- Activate using the release property: mvn clean install -Prelease -->
335334
<profile>
336335
<id>release</id>
337-
<activation>
338-
<property>
339-
<name>release</name>
340-
</property>
341-
</activation>
342-
343336
<build>
344337
<plugins>
345338
<!-- Release to Maven central -->
@@ -400,7 +393,6 @@
400393
<activation>
401394
<jdk>1.8</jdk>
402395
</activation>
403-
404396
<build>
405397
<plugins>
406398
<plugin>
@@ -419,5 +411,15 @@
419411
</plugins>
420412
</build>
421413
</profile>
414+
<profile>
415+
<!-- build example apps by default but exclude them from the release -->
416+
<id>defaultBuild</id>
417+
<activation>
418+
<activeByDefault>true</activeByDefault>
419+
</activation>
420+
<modules>
421+
<module>graphql-kotlin-spring-example</module>
422+
</modules>
423+
</profile>
422424
</profiles>
423425
</project>

0 commit comments

Comments
 (0)