Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Difference between revisions of "Californium/Release Process"
(Added description for Hudson based release build) |
|||
Line 1: | Line 1: | ||
− | === | + | = How-to release Californium = |
+ | |||
+ | Californium consists of the following components | ||
+ | * Element Connector | ||
+ | * Californium (parent) | ||
+ | * Californium (core) | ||
+ | * Scandium | ||
+ | * Tools | ||
+ | * Actinium | ||
+ | |||
+ | === Repositories === | ||
+ | |||
+ | The source code for these components is managed in separate GitHub repositories as follows: | ||
+ | {| class="wikitable" | ||
+ | |Element Connector | ||
+ | |https://github.com/eclipse/californium.element-connector.git | ||
+ | |- | ||
+ | |Californium (parent) | ||
+ | |https://github.com/eclipse/californium.git | ||
+ | |- | ||
+ | |Californium (core) | ||
+ | |https://github.com/eclipse/californium.core.git | ||
+ | |- | ||
+ | |Scandium | ||
+ | |https://github.com/eclipse/californium.scandium.git | ||
+ | |- | ||
+ | |Tools | ||
+ | |https://github.com/eclipse/californium.tools.git | ||
+ | |- | ||
+ | |Actinium | ||
+ | |https://github.com/eclipse/californium.actinium.git | ||
+ | |- | ||
+ | |} | ||
+ | |||
+ | In order to create a release from the command line, all these repositories need to be checked out first: | ||
+ | |||
+ | <code> | ||
+ | git clone git@github.com:eclipse/californium.element-connector.git | ||
+ | |||
+ | git clone git@github.com:eclipse/californium.scandium.git | ||
+ | |||
+ | git clone git@github.com:eclipse/californium.git | ||
+ | |||
+ | git clone git@github.com:eclipse/californium.core.git | ||
+ | |||
+ | git clone git@github.com:eclipse/californium.tools.git | ||
+ | |||
+ | git clone git@github.com:eclipse/californium.actinium.git | ||
+ | </code> | ||
+ | |||
+ | Some of the components have dependencies on other components. Thus, the repositories need to be built in the following order: | ||
+ | |||
+ | # Californium (parent) | ||
+ | # Element Connector | ||
+ | # Californium (core) | ||
+ | # Scandium | ||
+ | # Tools | ||
+ | # Actinium | ||
+ | |||
+ | === Release Process === | ||
+ | |||
+ | The following table contains instructions for building and releasing a single repository both from the command line as well as from a Hudson build job. | ||
+ | |||
+ | {| class="wikitable" | ||
+ | !Step | ||
+ | !Command Line | ||
+ | !Hudson | ||
+ | |- | ||
+ | |Create build job | ||
+ | | nothing to do | ||
+ | | | ||
+ | # Create a new build job using the '''Build a free-style software job''' option | ||
+ | # Check the '''This build is parameterized''' checkbox and add the following parameters: | ||
+ | ## '''RELEASE_VERSION''' - no '''Default Value''' necessary | ||
+ | ## '''NEXT_VERSION''' - no '''Default Value''' necessary | ||
+ | # Under '''Advanced Job Options''' click the '''Advanced...''' button | ||
+ | # Check the '''Clean workspace before build''' checkbox | ||
+ | |- | ||
+ | |Checkout repository | ||
+ | |<code>git clone git@github.com:eclipse/californium.git</code> | ||
+ | |Fill out '''Source Code Management''' section of build configuration like this: | ||
+ | # '''Url of repository''': ''ssh://deploy_github_eclipse_californium/eclipse/californium.git'' | ||
+ | # '''Branch specifier''': ''master'' | ||
+ | # click '''Advanced...''' button in the '''Branches to build''' section to expand more options | ||
+ | # '''Checkout/merge to local branch''': ''master'' | ||
+ | # check '''Use Command line git to clone''' | ||
+ | |- | ||
+ | |Set release version (probably the same as the current one but without the ''-SNAPSHOT'' suffix) | ||
+ | | | ||
+ | <code> | ||
+ | mvn versions:set -DnewVersion=X.Y.Z | ||
+ | </code> | ||
+ | | | ||
+ | # In the '''Build''' section click the '''Add build step''' drop-down list and select '''Invoke Maven 3''' | ||
+ | # In the newly created build step set | ||
+ | ## '''Goals''': ''versions:set'' | ||
+ | ## '''Properties''': ''newVersion=${RELEASE_VERSION}'' | ||
+ | |- | ||
+ | |Build & test the code | ||
+ | | | ||
+ | <code> | ||
+ | mvn clean install | ||
+ | </code> | ||
+ | | | ||
+ | # Click the '''Add build step''' drop-down list and select '''Invoke Maven 3''' | ||
+ | # In the newly created build step set | ||
+ | ## '''Goals''': ''clean install'' | ||
+ | ## '''Properties''': ''maven.test.failure.ignore=false'' ''snapshotDependencyAllowed=false'' | ||
+ | |- | ||
+ | |Commit pom.xml containing the release version and create a corresponding tag for it | ||
+ | | | ||
+ | <code> | ||
+ | git add pom.xml \*/pom.xml | ||
+ | |||
+ | git commit -m "Release X.Y.Z" | ||
+ | |||
+ | git tag "X.Y.Z" | ||
+ | </code> | ||
+ | | | ||
+ | # Click the '''Add build step''' drop-down list and select '''Execute shell''' | ||
+ | # In the newly created build step add the following script <br/> | ||
+ | <code> | ||
+ | git add pom.xml \*/pom.xml | ||
+ | |||
+ | git commit -m "Release ${RELEASE_VERSION}" | ||
+ | |||
+ | git tag ${RELEASE_VERSION} | ||
+ | </code> | ||
+ | |- | ||
+ | |Publish artifacts to Eclipse release repository | ||
+ | | | ||
+ | <code>mvn deploy -DskipStaging=true -DenableEclipseJarSigner=true</code> | ||
+ | | | ||
+ | # Click the '''Add build step''' drop-down list and select '''Invoke Maven 3''' | ||
+ | # In the newly created build step set | ||
+ | ## '''Goals''': ''mvn:deploy'' | ||
+ | ## '''Properties''': ''skipStaging=true'' ''enableEclipseJarSigner=true'' | ||
+ | |- | ||
+ | |Publish artifacts to Maven Central's staging repo | ||
+ | | | ||
+ | <code>mvn deploy</code> | ||
+ | | | ||
+ | # Click the '''Add build step''' drop-down list and select '''Invoke Maven 3''' | ||
+ | # In the newly created build step set | ||
+ | ## '''Goals''': ''mvn:deploy'' | ||
+ | ## '''Properties''': ''createGPGSignature=true'' | ||
+ | |- | ||
+ | |Set next development version | ||
+ | | | ||
+ | <code> | ||
+ | mvn versions:set -DnewVersion=X.Y.Z-SNAPSHOT | ||
+ | </code> | ||
+ | | | ||
+ | # Click the '''Add build step''' drop-down list and select '''Invoke Maven 3''' | ||
+ | # In the newly created build step set | ||
+ | ## '''Goals''': ''versions:set'' | ||
+ | ## '''Properties''': ''newVersion=${NEXT_VERSION}'' | ||
+ | |- | ||
+ | |Push changes to SCM | ||
+ | | | ||
+ | <code> | ||
+ | git add pom.xml \*/pom.xml | ||
+ | |||
+ | git commit -m "Release X.Y.Z" | ||
+ | |||
+ | git push && git push --tags | ||
+ | </code> | ||
+ | | | ||
+ | # Click the '''Add build step''' drop-down list and select '''Execute shell''' | ||
+ | # In the newly created build step add the following script <br/> | ||
+ | <code> | ||
+ | git add pom.xml \*/pom.xml | ||
+ | |||
+ | git commit -m "Release ${RELEASE_VERSION}" | ||
+ | |||
+ | git push ssh://deploy_github_eclipse_californium/eclipse/californium.git && git push --tags ssh://deploy_github_eclipse_californium/eclipse/californium.git | ||
+ | </code> | ||
+ | |- | ||
+ | |} | ||
+ | |||
+ | = Reference Instructions = | ||
1st get a copy of '''all''' the californium repository: | 1st get a copy of '''all''' the californium repository: | ||
Line 87: | Line 267: | ||
---- | ---- | ||
− | + | = GPG Help = | |
Under CygWin the following error might occur: | Under CygWin the following error might occur: |
Revision as of 13:08, 27 October 2015
Contents
How-to release Californium
Californium consists of the following components
- Element Connector
- Californium (parent)
- Californium (core)
- Scandium
- Tools
- Actinium
Repositories
The source code for these components is managed in separate GitHub repositories as follows:
Element Connector | https://github.com/eclipse/californium.element-connector.git |
Californium (parent) | https://github.com/eclipse/californium.git |
Californium (core) | https://github.com/eclipse/californium.core.git |
Scandium | https://github.com/eclipse/californium.scandium.git |
Tools | https://github.com/eclipse/californium.tools.git |
Actinium | https://github.com/eclipse/californium.actinium.git |
In order to create a release from the command line, all these repositories need to be checked out first:
git clone git@github.com:eclipse/californium.element-connector.git
git clone git@github.com:eclipse/californium.scandium.git
git clone git@github.com:eclipse/californium.git
git clone git@github.com:eclipse/californium.core.git
git clone git@github.com:eclipse/californium.tools.git
git clone git@github.com:eclipse/californium.actinium.git
Some of the components have dependencies on other components. Thus, the repositories need to be built in the following order:
- Californium (parent)
- Element Connector
- Californium (core)
- Scandium
- Tools
- Actinium
Release Process
The following table contains instructions for building and releasing a single repository both from the command line as well as from a Hudson build job.
Step | Command Line | Hudson |
---|---|---|
Create build job | nothing to do |
|
Checkout repository | git clone git@github.com:eclipse/californium.git
|
Fill out Source Code Management section of build configuration like this:
|
Set release version (probably the same as the current one but without the -SNAPSHOT suffix) |
|
|
Build & test the code |
|
|
Commit pom.xml containing the release version and create a corresponding tag for it |
git commit -m "Release X.Y.Z" git tag "X.Y.Z" |
git commit -m "Release ${RELEASE_VERSION}" git tag ${RELEASE_VERSION} |
Publish artifacts to Eclipse release repository |
|
|
Publish artifacts to Maven Central's staging repo |
|
|
Set next development version |
|
|
Push changes to SCM |
git commit -m "Release X.Y.Z" git push && git push --tags |
git commit -m "Release ${RELEASE_VERSION}" git push ssh://deploy_github_eclipse_californium/eclipse/californium.git && git push --tags ssh://deploy_github_eclipse_californium/eclipse/californium.git |
Reference Instructions
1st get a copy of all the californium repository:
git clone git@github.com:eclipse/californium.element-connector.git
git clone git@github.com:eclipse/californium.scandium.git
git clone git@github.com:eclipse/californium.git
git clone git@github.com:eclipse/californium.tools.git
git clone git@github.com:eclipse/californium.actinium.git
You need to process the repository in the correct order:
element-connector
scandium
californium
tools
actinium
In each repository:
- set the final version (probably the same as the current one but without "SNAPSHOT")
mvn versions:set -DnewVersion=X.Y.Z
- build & sign the artifacts (you need a gpg key; see below)
mvn clean install -Prelease
- looks in ./target/ does the artifacts looks nice?
- check if there is no *-SNAPSHOT in the dependency:
mvn dependency:tree
- then commit the pom.xml, and tag the release:
git add pom.xml \*/pom.xml
git commit -m "Release X.Y.Z"
git tag "X.Y.Z"
- publish the artifacts on maven central
mvn deploy -Prelease
- prepare for the next cycle:
mvn versions:set -DnewVersion=X.Y.Z-SNAPSHOT
git add pom.xml \*/pom.xml
git commit -m "Release X.Y.Z"
- push the commits
git push && git push --tags
Now connect on the Sonatype OSS Nexus and close the staging repository. If it's fine you will be able to "release" the repository and the artifact will show up in maven central in a few hours. Next step is to edit the Eclipse project metadata and announce it on the mailing list.
GPG Help
Under CygWin the following error might occur:
gpg: cannot open tty `no tty': No such file or directory
This can be fixed by configuring gpg through an active profile in .m2\settings.xml
where also the Sonatype password is stored:
<settings> <servers> <server> <id>ossrh</id> <username>[username]</username> <password>[password]</password> </server> </servers> <profiles> <profile> <id>gpg</id> <properties> <gpg.executable>gpg</gpg.executable> <gpg.passphrase>[password]</gpg.passphrase> </properties> </profile> </profiles> <activeProfiles> <activeProfile>gpg</activeProfile> </activeProfiles> </settings>