<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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>com.github.crab2died</groupId>
    <artifactId>Excel4J</artifactId>
    <version>3.0.0</version>
    <packaging>jar</packaging>

    <name>Excel4J</name>
    <description>Excel and CSV operation component based on POI and Commons CSV</description>
    <url>https://github.com/Crab2died/Excel4J</url>

    <properties>
        <jdk.version>1.7</jdk.version>
        <poi.version>4.1.2</poi.version>
        <csv.version>1.8</csv.version>
        <junit.version>4.11</junit.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>

    <licenses>
        <license>
            <name>The Apache Software License, Version 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <scm>
        <url>https://github.com/Crab2died/Excel4J</url>
        <connection>scm:git:https://github.com/Crab2died/Excel4J.git</connection>
        <developerConnection>scm:git:https://github.com/Crab2died/Excel4J.git</developerConnection>
    </scm>

    <developers>
        <developer>
            <id>Crab2Died:Excel4J</id>
            <name>Crab2Died</name>
            <email>hwb9588@126.com</email>
            <roles>
                <role>all</role>
            </roles>
            <organizationUrl>https://gitee.com/Crab2Died</organizationUrl>
            <url>https://gitee.com/Crab2Died</url>
        </developer>
    </developers>

    <dependencies>

        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>${junit.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.poi</groupId>
            <artifactId>poi</artifactId>
            <version>${poi.version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.poi</groupId>
            <artifactId>poi-ooxml</artifactId>
            <version>${poi.version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-csv</artifactId>
            <version>${csv.version}</version>
        </dependency>
    </dependencies>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-compiler-plugin</artifactId>
                        <version>3.7.0</version>
                        <configuration>
                            <source>${jdk.version}</source>
                            <target>${jdk.version}</target>
                            <encoding>${project.build.sourceEncoding}</encoding>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <version>3.0.1</version>
                        <configuration>
                            <attach>true</attach>
                            <archive>
                                <manifestFile>src/main/resources/META-INF/MANIFEST.MF</manifestFile>
                                <manifest>
                                    <addClasspath>false</addClasspath>
                                    <classpathPrefix>lib/</classpathPrefix>
                                    <addDefaultSpecificationEntries>false</addDefaultSpecificationEntries>
                                    <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                                </manifest>
                                <manifestEntries>
                                    <copyright>Crab2Died</copyright>
                                </manifestEntries>
                            </archive>
                        </configuration>
                        <executions>
                            <execution>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <version>3.0.0</version>
                        <configuration>
                            <archive>
                                <manifestFile>src/main/resources/META-INF/MANIFEST.MF</manifestFile>
                                <manifest>
                                    <addClasspath>false</addClasspath>
                                    <classpathPrefix>lib/</classpathPrefix>
                                    <addDefaultSpecificationEntries>false</addDefaultSpecificationEntries>
                                    <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                                </manifest>
                                <manifestEntries>
                                    <copyright>Crab2Died</copyright>
                                </manifestEntries>
                            </archive>
                        </configuration>
                        <executions>
                            <execution>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-jar-plugin</artifactId>
                        <version>3.0.2</version>
                        <configuration>
                            <archive>
                                <manifestFile>src/main/resources/META-INF/MANIFEST.MF</manifestFile>
                                <manifest>
                                    <addClasspath>false</addClasspath>
                                    <classpathPrefix>lib/</classpathPrefix>
                                    <addDefaultSpecificationEntries>false</addDefaultSpecificationEntries>
                                    <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                                </manifest>
                                <manifestEntries>
                                    <copyright>Crab2Died</copyright>
                                </manifestEntries>
                            </archive>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>1.6</version>
                        <executions>
                            <execution>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>

            <distributionManagement>
                <repository>
                    <id>ossrh</id>
                    <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
                </repository>
                <snapshotRepository>
                    <id>ossrh</id>
                    <url>https://oss.sonatype.org/content/repositories/snapshots/</url>
                </snapshotRepository>
            </distributionManagement>
        </profile>
    </profiles>

</project>
