<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>com.extrawest</groupId>
    <artifactId>Extrawest-OCPI-2.2.1-EMSP-Server</artifactId>
    <version>2023.11.21</version>

    <name>Extrawest-OCPI-2.2.1-EMSP-Server</name>
    <description>Extrawest-OCPI-2.2.1-EMSP-Server</description>
    <url>https://github.com/extrawest/Extrawest-OCPI-2.2.1-EMSP-Server</url>
    <inceptionYear>2023</inceptionYear>
    <licenses>
        <license>
            <name>MIT License</name>
            <url>http://www.opensource.org/licenses/mit-license.php</url>
        </license>
    </licenses>
    <developers>
        <developer>
            <name>Galyna Klymenko</name>
            <email>galyna.klymenko@extrawest.com</email>
            <organization>extrawest</organization>
            <organizationUrl>https://www.extrawest.com/</organizationUrl>
        </developer>
    </developers>
    <organization>
        <name>Extrawest</name>
        <url>https://www.extrawest.com/</url>
    </organization>
    <scm>
        <connection>scm:git:git://github.com/extrawest/Extrawest-OCPI-2.2.1-EMSP-Server.git</connection>
        <developerConnection>scm:git:ssh://github.com/extrawest/Extrawest-OCPI-2.2.1-EMSP-Server.git</developerConnection>
        <url>https://github.com/extrawest/Extrawest-OCPI-2.2.1-EMSP-Server</url>
    </scm>

    <parent>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-parent</artifactId>
        <version>3.0.2</version>
        <relativePath/>
    </parent>

    <properties>
        <java.version>17</java.version>
        <mapstruct.version>1.5.3.Final</mapstruct.version>
        <org.lombok.version>1.18.24</org.lombok.version>
        <lombok.mapstruct.version>0.2.0</lombok.mapstruct.version>
        <maven.plugin.version>3.10.1</maven.plugin.version>
    </properties>
    <dependencies>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-validation</artifactId>
        </dependency>
        <dependency>
            <groupId>org.mapstruct</groupId>
            <artifactId>mapstruct</artifactId>
            <version>${mapstruct.version}</version>
        </dependency>
        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
            <optional>true</optional>
        </dependency>
        <dependency>
            <groupId>javax.persistence</groupId>
            <artifactId>javax.persistence-api</artifactId>
            <version>2.2</version>
        </dependency>
        <!--        swagger + open-api-generator     -->
        <dependency>
            <groupId>org.springdoc</groupId>
            <artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
            <version>2.0.4</version>
        </dependency>
        <dependency>
            <groupId>org.springdoc</groupId>
            <artifactId>springdoc-openapi-ui</artifactId>
            <version>1.6.15</version>
        </dependency>
        <!--        javax       -->
        <dependency>
            <groupId>javax.validation</groupId>
            <artifactId>validation-api</artifactId>
            <version>2.0.1.Final</version>
        </dependency>
        <dependency>
            <groupId>javax.annotation</groupId>
            <artifactId>javax.annotation-api</artifactId>
            <version>1.3.2</version>
        </dependency>
        <!--        javax       -->

        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-core</artifactId>
            <version>2.15.2</version>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.datatype</groupId>
            <artifactId>jackson-datatype-jsr310</artifactId>
            <version>2.15.2</version>
        </dependency>
    </dependencies>

    <build>
        <finalName>${project.name}</finalName>
        <plugins>
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <version>3.0.2</version>
                <configuration>
                    <skip>true</skip>
                    <classifier>exec</classifier>
                    <excludes>
                        <exclude>
                            <groupId>org.projectlombok</groupId>
                            <artifactId>lombok</artifactId>
                        </exclude>
                    </excludes>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>3.2.1</version>
                <executions>
                    <execution>
                        <id>attach-source</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>${maven.plugin.version}</version>
                <configuration>
                    <annotationProcessorPaths>
                        <path>
                            <groupId>org.mapstruct</groupId>
                            <artifactId>mapstruct-processor</artifactId>
                            <version>${mapstruct.version}</version>
                        </path>
                        <path>
                            <groupId>org.projectlombok</groupId>
                            <artifactId>lombok</artifactId>
                            <version>${org.lombok.version}</version>
                        </path>
                        <path>
                            <groupId>org.projectlombok</groupId>
                            <artifactId>lombok-mapstruct-binding</artifactId>
                            <version>${lombok.mapstruct.version}</version>
                        </path>
                    </annotationProcessorPaths>
                    <compilerArgs>
                        <compilerArg>-Amapstruct.defaultComponentModel=spring</compilerArg>
                    </compilerArgs>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.jreleaser</groupId>
                <artifactId>jreleaser-maven-plugin</artifactId>
                <version>1.5.0</version>
                <configuration>
                    <jreleaser>
                        <project>
                            <description>OCPI library for eMSP operations</description>
                            <website>https://github.com/extrawest/Extrawest-OCPI-2.2.1-EMSP-Server/tree/main</website>
                            <docsUrl>https://github.com/extrawest/Extrawest-OCPI-2.2.1-EMSP-Server/tree/main</docsUrl>
                            <license>APACHE-2.0</license>
                            <copyright>2023 Extrawest</copyright>
                        </project>
                        <signing>
                            <active>ALWAYS</active>
                            <armored>true</armored>
                        </signing>
                        <deploy>
                            <maven>
                                <nexus2>
                                    <maven-central>
                                        <active>ALWAYS</active>
                                        <url>https://s01.oss.sonatype.org/service/local</url>;
                                        <closeRepository>false</closeRepository>
                                        <releaseRepository>false</releaseRepository>
                                        <stagingRepositories>target/staging-deploy</stagingRepositories>
                                        <snapshotUrl>https://s01.oss.sonatype.org/content/repositories/snapshots/</snapshotUrl>
                                    </maven-central>
                                </nexus2>
                            </maven>
                        </deploy>
                    </jreleaser>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <version>3.5.0</version>
                        <configuration>
                            <doclint>none</doclint>
                        </configuration>
                        <executions>
                            <execution>
                                <id>attach-javadoc</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <distributionManagement>
        <!-- Sonatype Repository -->
        <repository>
            <id>sonatype-nexus-releases</id>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>

        <!-- GitHub Releases -->
        <snapshotRepository>
            <id>github</id>
            <url>https://maven.pkg.github.com/extrawest/extrawest-ocpi-2.2.1-emsp-server</url>
            <name>GitHub Package Registry</name>
            <uniqueVersion>false</uniqueVersion>
        </snapshotRepository>
    </distributionManagement>

</project>
