Page History
...
With DSpace 6 we changed the maven plugin that pushes our releases to Sonatype. The configuration above is correct beginning with DSpace 6. In case you release a previous DSpace version, you'll need to copy the server section two times and change the id to sonatype-nexus-snapshots
and
A settings file that allows you to release all versions of DSpace would look like the following example:sonatype-nexus-staging.
Code Block |
---|
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd"> <servers> <!--Login info for Sonatype SnapShot repository--> <server> <id>ossrh</id> <username>YourSonatypeUsername</username> <password>YourSonatypePassword</password> </server> <!--Login info for Sonatype SnapShot repository--> <server> <id>sonatype-nexus-snapshots</id> <username>YourSonatypeUsername</username> <password>YourSonatypePassword</password> </server> <!--Login info for Sonatype Staging/Release repository--> <server> <id>sonatype-nexus-staging</id> <username>YourSonatypeUsername</username> <password>YourSonatypePassword</password> </server> </servers> </settings> |
...
Code Block | ||
---|---|---|
| ||
unset MAVEN_OPTS |
It's highly unlikely the configuration in your MAVEN_OPTS will be useful for the release. It's highly likely to cause problems. Better to be safe.
...
-
dspace-api-lang
- Check if any new commits have occurred on 'dspace-api-lang' since the last release. -
dspace-xmlui-lang
- Check if any new commits have occurred on 'dspace-xmlui-lang' since the last release. (For v6.x or below)
Info | ||
---|---|---|
| ||
Note that the version numbering convention for Language Packs is always the same as the current DSpace release, with an additional |
...
- Checkout the Language Pack Module:
git clone git
@github.
com:DSpace/dspace-api-lang.git dspace-api-lang
cd dspace-api-lang
git checkout master main
NOTE: always release language packs from the master main branch -- we do not use a maintenance branch for language packs.
- Do a Dry Run:
mvn release:prepare -DdryRun=true
- Tag and Increment Version:
mvn release:prepare -Dresume=false
- Make sure to assign a version number of the format:
[major].[minor].[sequence-number]
(e.g. 5.0.0, 5.0.1, etc for 5.0 releases of language packs) - NOTE: The release process should suggest the correct version number by default
- Make sure to assign a version number of the format:
- Deploy Artifacts to Staging in Sonatype:
mvn release:perform
- Verify and Release Staged Artifacts in Sonatype (see instructions at link)
- (For v6.x or below) Go back and run steps #1-5 above for the other language packs modules (dspace-xmlui-lang)
...
Info |
---|
NOTE: if you're skimming these instructions, you may be tempted to think you've already handled this step, because you have already released new language packs, as detailed above. If you think so, you probably have NOT yet completed the steps below. The steps below tell DSpace what version of language packs to use. The language packs you've released following the steps above won't ever get used if you don't do the steps below. This is an easy thing to miss. Don't. Just check, to be sure. |
...
Once the Language Packs are released, you will probably need to modify the DSpace root pom.xml (https://github.com/DSpace/DSpace/blob/master/pom.xml) to reference the new version of the Language Packs. This should be similar to the following:
...
Code Block |
---|
mvn test -Dmaven.test.skip=false -DskipITs=false |
...
Do a Dry Run
This step is not required, but performs a useful sanity check without committing any changes. From your clean, up-to-date copy of master/branch, run the following command (from [dspace-src]
):
...
What to do if you get tagging Errors?
Note | ||
---|---|---|
| ||
The
|
...
Note | ||
---|---|---|
If you run into issues, or need to perform the
|
Verify and Release Staged Artifacts in Sonatype
...
This is a known bug in Maven. The problem is that you likely have a 'dspace-xmlui-lang' or 'dspace-api-lang' folder at the same level as your [dspace-source] parent folder. Essentially, Maven located them and tried to add them into the build process (which it shouldn't have). The fix is to completely delete the "dspace-xmlui-lang" and "dspace-api-lang" folders, and try to rebuild DSpace.
Advice for future Release Coordinators
With a straight face assure the next Release Coordinator that "Maven is easy" and there is nothing to be afraid of, then put your feet up and open a beer.