Skip to content

Commit 4c02514

Browse files
aksOpsclaude
andcommitted
feat: add source bundle via maven-assembly-plugin
Produces code-iq-VERSION-source-bundle.zip/.tar.gz during mvn package. Contains the full project source tree (src/, pom.xml, README, LICENSE, .github/, ANTLR grammars) without build artifacts (node_modules, dist, generated sources, target/). Bundle is ~1.3MB compressed. Attached as a Maven artifact for distribution alongside the compiled JAR. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 0c97e12 commit 4c02514

2 files changed

Lines changed: 80 additions & 0 deletions

File tree

pom.xml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -331,6 +331,28 @@
331331
</configuration>
332332
</plugin>
333333

334+
<!-- Source bundle: full project source tree as a distributable ZIP -->
335+
<plugin>
336+
<groupId>org.apache.maven.plugins</groupId>
337+
<artifactId>maven-assembly-plugin</artifactId>
338+
<configuration>
339+
<descriptors>
340+
<descriptor>src/assembly/source-bundle.xml</descriptor>
341+
</descriptors>
342+
<finalName>${project.artifactId}-${project.version}</finalName>
343+
<appendAssemblyId>true</appendAssemblyId>
344+
</configuration>
345+
<executions>
346+
<execution>
347+
<id>create-source-bundle</id>
348+
<phase>package</phase>
349+
<goals>
350+
<goal>single</goal>
351+
</goals>
352+
</execution>
353+
</executions>
354+
</plugin>
355+
334356
</plugins>
335357
</build>
336358

src/assembly/source-bundle.xml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
<assembly xmlns="http://maven.apache.org/ASSEMBLY/2.2.0"
2+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xsi:schemaLocation="http://maven.apache.org/ASSEMBLY/2.2.0 https://maven.apache.org/xsd/assembly-2.2.0.xsd">
4+
5+
<id>source-bundle</id>
6+
<formats>
7+
<format>zip</format>
8+
<format>tar.gz</format>
9+
</formats>
10+
11+
<includeBaseDirectory>true</includeBaseDirectory>
12+
<baseDirectory>${project.artifactId}-${project.version}</baseDirectory>
13+
14+
<fileSets>
15+
<!-- Project root files -->
16+
<fileSet>
17+
<directory>${project.basedir}</directory>
18+
<outputDirectory>/</outputDirectory>
19+
<includes>
20+
<include>pom.xml</include>
21+
<include>README.md</include>
22+
<include>CLAUDE.md</include>
23+
<include>LICENSE</include>
24+
<include>.gitignore</include>
25+
<include>sonar-project.properties</include>
26+
</includes>
27+
</fileSet>
28+
29+
<!-- All source code -->
30+
<fileSet>
31+
<directory>${project.basedir}/src</directory>
32+
<outputDirectory>/src</outputDirectory>
33+
<includes>
34+
<include>**/*</include>
35+
</includes>
36+
<excludes>
37+
<!-- Frontend build artifacts -->
38+
<exclude>main/frontend/node_modules/**</exclude>
39+
<exclude>main/frontend/node/**</exclude>
40+
<exclude>main/frontend/dist/**</exclude>
41+
<exclude>main/frontend/.cache/**</exclude>
42+
<exclude>main/frontend/tsconfig.tsbuildinfo</exclude>
43+
<!-- ANTLR generated sources -->
44+
<exclude>**/grammar/**/generated/**</exclude>
45+
</excludes>
46+
</fileSet>
47+
48+
<!-- GitHub workflows -->
49+
<fileSet>
50+
<directory>${project.basedir}/.github</directory>
51+
<outputDirectory>/.github</outputDirectory>
52+
<includes>
53+
<include>**/*</include>
54+
</includes>
55+
</fileSet>
56+
</fileSets>
57+
58+
</assembly>

0 commit comments

Comments
 (0)