Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

You can use the Maven Release plug-in to package and release your Developer Studio projects. As a practice, at the development stage of the project, it is the SNAPSHOT version of the artifacts that is used. This is similar to the next major/minor version to be released. For example, if the next planned release version is 1.1.0, it is 1.1.0-SNAPSHOT that is used for versioning in the development stage.

Follow the steps below to deploy WSO2 artifacts to a nexus repository:

Warning
Make sure you are using WSO2 Developer Studio 3.7.1 or upwards.
  1. In the pom.xml file, configure the SCM configuration. For example,

    Code Block
    languagexml
     <scm>
        <connection>scm:svn:https://svn.wso2.com/wso2/interns/2013/vijithae/release/trunk</connection>
        <developerConnection>scm:svn:https://svn.wso2.com/wso2/interns/2013/vijithae/release/trunk</developerConnection>
        <url>https://svn.wso2.com/wso2/interns/2013/vijithae/release/trunk</url>
      </scm>
  2. Point to the nexus repository of the project. For example,

    Code Block
    languagexml
    <distributionManagement>
           <repository>
               <id>deployment</id>
               <name>Internal Releases</name>
               <url>http://localhost:8081/nexus/content/repositories/releases/</url>
           </repository>
           <snapshotRepository>
               <id>deployment</id>
               <name>Internal Snapshot Releases</name>
               <url>http://localhost:8081/nexus/content/repositories/snapshots/</url>
           </snapshotRepository>
       </distributionManagement>
  3. Configure with the wso2-release-helper-plugin and tag base. For example,

    Code Block
    languagexml
    <plugin>
        <artifactId>maven-release-plugin</artifactId>
        <version>2.5</version>
        <configuration>
    	 <preparationGoals>               
              org.wso2.maven:wso2-release-helper-plugin:1.0.0-SNAPSHOT:prepare-release
           </preparationGoals>
           <completionGoals>
              org.wso2.maven:wso2-release-helper-plugin:1.0.0-SNAPSHOT:prepare-snapshots
           </completionGoals>
    <tagBase>https://svn.wso2.com/wso2/interns/2013/vijithae/release/tags</tagBase>
        </configuration>
    </plugin>
    Info

    Note that the wso2-release-pre-prepare-plugin is now deprecated since the plug-in only supported svn and provided no support for rollbacks, dryRun mode etc.  

  4. Execute the mvn release:prepare command inside the Maven Multi Module project. Give appropriate values for release, development, and tag versions when prompted.
  5. Execute the mvn release:perform command inside the Maven Multi Module project.

For complete information on the Maven Release plug-in, see the Maven Release Plugin page on the Apache website. For complete information on the WSO2 Release Helper plug-in, see Using WSO2 Release Helper Plug-In.