Skip to content
This repository was archived by the owner on Jun 26, 2026. It is now read-only.
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

159 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

string-template-maven-plugin

Maven Central Maven Central (snapshot) Codecov Java Version

string-template-maven-plugin

JVM Platform Status
OpenJDK (Temurin) Current Linux Build (OpenJDK (Temurin) Current, Linux)
OpenJDK (Temurin) LTS Linux Build (OpenJDK (Temurin) LTS, Linux)
OpenJDK (Temurin) Current Windows Build (OpenJDK (Temurin) Current, Windows)
OpenJDK (Temurin) LTS Windows Build (OpenJDK (Temurin) LTS, Windows)

Repository Relocation

Development of this project has moved to an open-source but not open-contribution model.

Source code and commits will remain publicly available perpetually, but issues and/or pull requests will be rejected and/or ignored. Additionally, this project will now only be available via a read-only mirror at:

https://codeberg.org/io7m-com/string-template-maven-plugin

string-template-maven-plugin

The string-template-maven-plugin package provides a plugin to execute StringTemplate templates during a build.

Usage

An example of generating a PAreasBDTest.java file from a template named PAreasTest in src/main/string-template/PAreasTest.st:

<build>
  <plugins>
...

<plugin>
  <groupId>com.io7m.stmp</groupId>
  <artifactId>string-template-maven-plugin</artifactId>
  <executions>
    <execution>
      <id>generate-area-P-BD</id>
      <phase>generate-sources</phase>
      <goals>
        <goal>renderTemplate</goal>
      </goals>
      <configuration>
        <template>
          <name>PAreasTest</name>
          <inputFile>
            ${project.basedir}/src/main/string-template/PAreasTest.st
          </inputFile>
          <outputFile>
            ${project.build.directory}/generated-sources/string-template/com/io7m/jregions/tests/core/parameterized/PAreasBDTest.java
          </outputFile>
          <properties>
            <scalarType>java.math.BigDecimal</scalarType>
            <scalarGeneratorType>Generator&lt;java.math.BigDecimal&gt;</scalarGeneratorType>
            <areaType>com.io7m.jregions.core.parameterized.areas.PAreaBD</areaType>
            <areaSizeType>com.io7m.jregions.core.parameterized.sizes.PAreaSizeBD</areaSizeType>
            <areaOpsType>com.io7m.jregions.core.parameterized.areas.PAreasBD</areaOpsType>
            <className>PAreasBDTest</className>
            <splitXType>com.io7m.jregions.core.parameterized.areas.PAreaXSplitBD</splitXType>
            <splitYType>com.io7m.jregions.core.parameterized.areas.PAreaYSplitBD</splitYType>
            <splitXYType>com.io7m.jregions.core.parameterized.areas.PAreaXYSplitBD</splitXYType>
            <opClass>PAreasBDTestOps</opClass>
          </properties>
        </template>
      </configuration>
    </execution>
  </executions>
</plugin>

...
  </plugins>
</build>

About

Execute StringTemplate files during your Maven build.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Used by

Contributors

Languages