<?xml version="1.0"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>com.github.martinpaljak</groupId>
    <artifactId>metacard</artifactId>
    <version>20.02.19</version>
  </parent>
  <groupId>com.github.martinpaljak</groupId>
  <artifactId>ant-javacard</artifactId>
  <version>20.03.25</version>
  <name>ant-javacard</name>
  <description>Easy to use Ant task for building JavaCard applets</description>
  <url>https://github.com/martinpaljak/ant-javacard</url>
  <inceptionYear>2015</inceptionYear>
  <licenses>
    <license>
      <name>MIT</name>
      <url>https://github.com/martinpaljak/ant-javacard/blob/master/LICENSE</url>
      <distribution>repo</distribution>
    </license>
  </licenses>
  <developers>
    <developer>
      <id>martinpaljak</id>
      <name>Martin Paljak</name>
      <email>martin@martinpaljak.net</email>
    </developer>
  </developers>
  <scm>
    <url>https://github.com/martinpaljak/ant-javacard</url>
  </scm>
  <dependencies>
    <dependency>
      <groupId>org.apache.ant</groupId>
      <artifactId>ant</artifactId>
      <version>1.8.2</version>
      <scope>provided</scope>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>com.github.martinpaljak</groupId>
      <artifactId>capfile</artifactId>
      <version>20.02.19</version>
      <scope>compile</scope>
    </dependency>
  </dependencies>
  <repositories>
    <repository>
      <id>javacard-pro</id>
      <name>javacard.pro</name>
      <url>https://javacard.pro/maven/</url>
    </repository>
  </repositories>
  <build>
    <plugins>
      <plugin>
        <artifactId>maven-shade-plugin</artifactId>
        <version>3.2.1</version>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>shade</goal>
            </goals>
            <configuration>
              <finalName>ant-javacard</finalName>
              <transformers>
                <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
                  <mainClass>pro.javacard.ant.DummyMain</mainClass>
                </transformer>
              </transformers>
              <filters>
                <filter>
                  <artifact>*:*</artifact>
                  <excludes>
                    <exclude>META-INF/maven/**</exclude>
                  </excludes>
                </filter>
              </filters>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>pl.project13.maven</groupId>
        <artifactId>git-commit-id-plugin</artifactId>
        <version>4.0.0</version>
        <executions>
          <execution>
            <id>retrieve-git-info</id>
            <phase>prepare-package</phase>
            <goals>
              <goal>revision</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <injectAllReactorProjects>true</injectAllReactorProjects>
          <runOnlyOnce>true</runOnlyOnce>
          <skipPoms>false</skipPoms>
          <dateFormat>yyyyMMddHHmmss</dateFormat>
          <dateFormatTimeZone>UTC</dateFormatTimeZone>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-jar-plugin</artifactId>
        <version>3.2.0</version>
        <configuration>
          <archive>
            <manifestEntries>
              <Last-Commit-Id>${git.commit.id}</Last-Commit-Id>
              <Last-Commit-Time>${git.commit.time}</Last-Commit-Time>
              <Reproducible-Build>true</Reproducible-Build>
            </manifestEntries>
          </archive>
        </configuration>
      </plugin>
      <plugin>
        <groupId>io.github.zlika</groupId>
        <artifactId>reproducible-build-maven-plugin</artifactId>
        <version>0.11</version>
        <executions>
          <execution>
            <id>strip-jar</id>
            <goals>
              <goal>strip-jar</goal>
            </goals>
            <configuration>
              <zipDateTime>${git.commit.time}</zipDateTime>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
</project>
