<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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>io.github.abdi-icap</groupId>
    <artifactId>ethiopiaemr-package</artifactId>
    <version>1.0.3</version>
    <name>EthiopiaEMR Content Package</name>
    <description>Contain Configuration files for OpenMRS backend and frontend</description>
    <packaging>pom</packaging>
    <url>https://github.com/palladium-group/ethiopiaemr-openmrs-content</url>
    <organization>
        <name>ICAP At Columbia Unversity</name>
    </organization>

    <developers>
        <developer>
            <name>OpenMRS</name>
            <organization>OpenMRS</organization>
            <organizationUrl>http://openmrs.org</organizationUrl>
        </developer>
        <developer>
            <name>Donald Kibet</name>
            <organization>Palladium Kenya</organization>
            <organizationUrl>http://kenyahmis.org</organizationUrl>
        </developer>
    </developers>

    <licenses>
        <license>
            <name>Apache 2</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>
    <scm>
        <connection>scm:git:git@github.com:palladiumkenya/openmrs-content-kenyahmis.git</connection>
        <developerConnection>scm:git:git@github.com:palladiumkenya/openmrs-content-kenyahmis.git</developerConnection>
        <url>https://github.com/palladiumkenya/openmrs-content-kenyahmis.git</url>
    </scm>
    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <configuration.dir>${project.basedir}/configuration</configuration.dir>
    </properties>
    <build>
        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-gpg-plugin</artifactId>
                <version>3.2.4</version>
                <executions>
                    <execution>
                        <id>sign-artifacts</id>
                        <phase>verify</phase>
                        <goals>
                            <goal>sign</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <bestPractices>true</bestPractices>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>3.3.1</version>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar-no-fork</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.sonatype.central</groupId>
                <artifactId>central-publishing-maven-plugin</artifactId>
                <version>0.6.0</version>
                <extensions>true</extensions>
                <configuration>
                    <publishingServerId>central</publishingServerId>
                    <autoPublish>true</autoPublish>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>3.6.3</version>
                <executions>
                    <execution>
                        <id>attach-javadocs</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <failOnError>false</failOnError>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.openmrs.maven.plugins</groupId>
                <artifactId>openmrs-packager-maven-plugin</artifactId>
                <version>1.9.0-SNAPSHOT</version>
                <executions>
                    <execution>
                        <id>validate-content-package</id>
                        <phase>verify</phase>
                        <goals>
                            <goal>validate-content-package</goal>
                        </goals>
                        <configuration>
                            <sourceFile>${project.basedir}/content.properties</sourceFile>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-assembly-plugin</artifactId>
                <version>3.7.1</version>
                <executions>
                    <execution>
                        <id>make-assembly</id>
                        <phase>package</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                        <configuration>
                            <descriptors>
                                <descriptor>${project.basedir}/assembly.xml</descriptor>
                            </descriptors>
                            <!-- Setting appendAssemblyId to false ensures that the assembly ID
                            is not appended to the final name of the assembled artifact -->
                            <appendAssemblyId>false</appendAssemblyId>
                            <finalName>${project.artifactId}-${project.version}</finalName>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>3.1.1</version>
                <configuration>
                    <autoVersionSubmodules>true</autoVersionSubmodules>
                    <useReleaseProfile>false</useReleaseProfile>
                    <releaseProfiles>release</releaseProfiles>
                    <preparationGoals>clean install</preparationGoals>
                    <goals>deploy</goals>
                    <tagNameFormat>@{project.version}</tagNameFormat>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-resources-plugin</artifactId>
                <version>3.3.1</version>
                <executions>
                    <execution>
                        <id>copy-resources</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>resources</goal>
                        </goals>
                        <configuration>
                            <outputDirectory>${project.build.directory}</outputDirectory>
                            <resources>
                                <resource>
                                    <directory>${project.basedir}</directory>
                                    <includes>
                                        <include>content.properties</include>
                                    </includes>
                                    <filtering>true</filtering>
                                </resource>
                            </resources>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
    <repositories>
        <repository>
            <id>openmrs-repo</id>
            <name>OpenMRS Public Repository</name>
            <url>https://mavenrepo.openmrs.org/public</url>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </repository>
        <repository>
            <id>openmrs-snapshots</id>
            <name>OpenMRS Snapshot Repository</name>
            <url>https://mavenrepo.openmrs.org/snapshots</url>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
        </repository>
        <repository>
            <id>central</id>
            <name>Maven Repository Switchboard</name>
            <url>https://repo1.maven.org/maven2</url>
        </repository>
    </repositories>
    <pluginRepositories>
        <pluginRepository>
            <id>openmrs-releases</id>
            <name>OpenMRS Public</name>
            <url>https://mavenrepo.openmrs.org/public</url>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </pluginRepository>
        <pluginRepository>
            <id>openmrs-snapshots</id>
            <name>OpenMRS Snapshots</name>
            <url>https://mavenrepo.openmrs.org/snapshots</url>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
        </pluginRepository>
    </pluginRepositories>
    <!-- <distributionManagement>
        <repository>
            <id>mks-repo</id>
            <name>Mekom Solutions Nexus Releases</name>
            <url>https://maven-repo.dh.moh.gov.et/repository/maven-releases</url>
        </repository>
        <snapshotRepository>
            <id>mks-repo-snapshots</id>
            <name>Mekom Solutions Nexus Snapshots</name>
            <url>https://maven-repo.dh.moh.gov.et/repository/maven-snapshots</url>
        </snapshotRepository>
    </distributionManagement> -->
</project>