Skip to content

Commit

Permalink
Merge pull request #13 from Bahmni/BAH-2849
Browse files Browse the repository at this point in the history
BAH-2849 | Setup and configuration for nexus release
  • Loading branch information
mohan-13 authored Feb 28, 2023
2 parents c1ba21f + 4a3bc1e commit 00e5743
Show file tree
Hide file tree
Showing 5 changed files with 107 additions and 43 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/build_publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ jobs:
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Set AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.S3_MVN_ACCESS_KEY }}
aws-secret-access-key: ${{ secrets.S3_MVN_SECRET_KEY }}
aws-region: ap-southeast-1
server-id: nexus-sonatype
server-username: NEXUS_USERNAME
server-password: NEXUS_PASSWORD
- name: Build and deploy with Maven
run: ./mvnw --no-transfer-progress clean -U deploy -Pmybahmni-s3
run: ./mvnw --no-transfer-progress clean -U deploy
env:
NEXUS_USERNAME: ${{ secrets.NEXUS_USERNAME }}
NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}

4 changes: 2 additions & 2 deletions api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openmrs.module</groupId>
<groupId>org.bahmni.module</groupId>
<artifactId>episodes</artifactId>
<version>1.0-SNAPSHOT</version>
<version>1.0.0-SNAPSHOT</version>
</parent>

<artifactId>episodes-api</artifactId>
Expand Down
14 changes: 7 additions & 7 deletions omod/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.openmrs.module</groupId>
<groupId>org.bahmni.module</groupId>
<artifactId>episodes</artifactId>
<version>1.0-SNAPSHOT</version>
<version>1.0.0-SNAPSHOT</version>
</parent>

<artifactId>episodes-omod</artifactId>
Expand All @@ -13,11 +13,11 @@
<description>Implementation of Episodes of Care for OpenMRS</description>

<dependencies>
<dependency>
<groupId>org.openmrs.module</groupId>
<artifactId>episodes-api</artifactId>
<version>${project.parent.version}</version>
</dependency>
<dependency>
<groupId>${project.parent.groupId}</groupId>
<artifactId>${project.parent.artifactId}-api</artifactId>
<version>${project.parent.version}</version>
</dependency>
<dependency>
<groupId>org.openmrs.web</groupId>
<artifactId>openmrs-web</artifactId>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package org.openmrs.module.episodes;

public class ModuleDescriptor {
}
114 changes: 87 additions & 27 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,38 @@
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>org.openmrs.module</groupId>
<groupId>org.bahmni.module</groupId>
<artifactId>episodes</artifactId>
<version>1.0-SNAPSHOT</version>
<version>1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>
<name>Episodes of Care Module</name>
<description>Implementation of Episodes of Care for OpenMRS</description>
<url>https://github.com/Bahmni/openmrs-module-episodes</url>
<organization>
<name>Bahmni</name>
<url>http://bahmni.org</url>
</organization>

<url>https://wiki.openmrs.org/x/_gBl</url>
<licenses>
<license>
<name>GNU AFFERO GENERAL PUBLIC LICENSE, Version 3.0</name>
<url>https://www.gnu.org/licenses/agpl-3.0.txt</url>
</license>
</licenses>
<developers>
<developer>
<name>Bahmni</name>
<email>[email protected]</email>
<organization>Bahmni</organization>
<organizationUrl>https://github.com/Bahmni</organizationUrl>
</developer>
</developers>
<scm>
<connection>scm:git:[email protected]:Bahmni/openmrs-module-episodes.git</connection>
<developerConnection>scm:git:[email protected]:Bahmni/openmrs-module-episodes.git</developerConnection>
<url>https://github.com/Bahmni/openmrs-module-episodes</url>
<tag>HEAD</tag>
</scm>

<modules>
<module>api</module>
Expand All @@ -18,10 +42,10 @@

<properties>
<openmrs.platform.version>2.4.2</openmrs.platform.version>
<MODULE_ID>episodes</MODULE_ID>
<MODULE_ID>${project.artifactId}</MODULE_ID>
<MODULE_NAME>${project.name}</MODULE_NAME>
<MODULE_VERSION>${project.version}</MODULE_VERSION>
<MODULE_PACKAGE>${project.groupId}.${MODULE_ID}</MODULE_PACKAGE>
<MODULE_PACKAGE>org.openmrs.module.${MODULE_ID}</MODULE_PACKAGE>
<MODULE_DESCRIPTION>${project.description}</MODULE_DESCRIPTION>
<REQUIRED_OPENMRS_VERSION>${openmrs.platform.version}</REQUIRED_OPENMRS_VERSION>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand All @@ -31,32 +55,68 @@
<javaxServletVersion>4.0.1</javaxServletVersion>
</properties>

<distributionManagement>
<snapshotRepository>
<id>nexus-sonatype</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
</snapshotRepository>
<repository>
<id>nexus-sonatype</id>
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url>
</repository>
</distributionManagement>

<profiles>
<profile>
<id>nexus-sonatype</id>
<id>release-sign-artifacts</id>
<activation>
<activeByDefault>true</activeByDefault>
<property>
<name>performRelease</name>
<value>true</value>
</property>
</activation>
<distributionManagement>
<snapshotRepository>
<id>nexus-sonatype</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
</snapshotRepository>
<repository>
<id>nexus-sonatype</id>
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url>
</repository>
</distributionManagement>
</profile>
<profile>
<id>mybahmni-s3</id>
<distributionManagement>
<snapshotRepository>
<id>repo.mybahmni.org</id>
<name>bahmni-artifactory-snapshots</name>
<url>s3://repo.mybahmni.org/artifactory/snapshot</url>
</snapshotRepository>
</distributionManagement>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>3.2.1</version>
<executions>
<execution>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.2.0</version>
<executions>
<execution>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>1.6</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<dependencyManagement>
Expand Down

0 comments on commit 00e5743

Please sign in to comment.