Skip to content

Commit 8cc62bb

Browse files
committed
build: sqldump-sonatype & docs changes
1 parent bc7da21 commit 8cc62bb

File tree

3 files changed

+48
-10
lines changed

3 files changed

+48
-10
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,8 @@ Artifact repositories
174174
---------------------
175175

176176
**Releases:**
177-
- [maven central](https://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.bitbucket.tbrugz%22%20AND%20a%3A%22sqldump%22)
177+
- [maven central/sqldump](https://central.sonatype.com/artifact/org.bitbucket.tbrugz/sqldump/versions)
178+
[maven central/org.bitbucket.tbrugz](https://central.sonatype.com/namespace/org.bitbucket.tbrugz)
178179

179180
**Snapshots:**
180181
- [sonatype snapshots](https://oss.sonatype.org/content/repositories/snapshots/org/bitbucket/tbrugz/)

build-sonatype.xml

Lines changed: 39 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,12 @@
4949
<echo message="maven-remoteRepositoryUrl: ${maven-remoteRepositoryUrl}" />
5050
</target>
5151

52+
<target name="mvn-info" depends="info">
53+
<artifact:mvn mavenHome="${maven.home}" fork="true" failonerror="true">
54+
<arg value="-version"/>
55+
</artifact:mvn>
56+
</target>
57+
5258
<target name="prepare-maven" depends="info">
5359
<path id="mvn.classpath">
5460
<fileset dir="${maven.home}/boot">
@@ -190,7 +196,7 @@
190196
</target>
191197

192198
<!-- before this, update project version (both build.xml and pom.xml) from SNAPSHOT to RELEASE -->
193-
<target name="stage" depends="prepare-publish-sonatype" description="deploy release version to Maven staging repository">
199+
<target name="stage" depends="prepare-maven, prepare-publish-sonatype" description="deploy release version to Maven staging repository">
194200
<echo message="artifactId: ${artifactId}"/>
195201
<fail message="Must NOT be SNAPSHOT version" if="version-snapshot"/>
196202

@@ -200,9 +206,26 @@
200206
<echo message="sonatype-nexus-staging.username: ${sonatype-nexus-staging.username}"/>
201207
<echo message="sonatype-nexus-staging.password: ${sonatype-nexus-staging.password}"/>
202208
-->
203-
204-
<!-- sign and deploy the main artifact -->
209+
<!--
205210
<artifact:mvn>
211+
<arg value="-v" />
212+
</artifact:mvn>
213+
-->
214+
215+
<java classname="${mvn.mainclass}" classpathref="mvn.classpath" fork="true" failonerror="true">
216+
<jvmarg value="-Dclassworlds.conf=${env.M2_HOME}/bin/m2.conf" />
217+
<jvmarg value="-Dmaven.home=${env.M2_HOME}" />
218+
<jvmarg value="-Dmaven.multiModuleProjectDirectory=${basedir}" />
219+
220+
<arg value="-v" />
221+
</java>
222+
223+
<!-- sign and deploy the main artifact -->
224+
<java classname="${mvn.mainclass}" classpathref="mvn.classpath" fork="true" failonerror="true">
225+
<jvmarg value="-Dclassworlds.conf=${env.M2_HOME}/bin/m2.conf" />
226+
<jvmarg value="-Dmaven.home=${env.M2_HOME}" />
227+
<jvmarg value="-Dmaven.multiModuleProjectDirectory=${basedir}" />
228+
206229
<arg value="org.apache.maven.plugins:maven-gpg-plugin:${maven-gpg-plugin.version}:sign-and-deploy-file" />
207230
<arg value="-Durl=${maven-staging-repository-url}" />
208231
<arg value="-DrepositoryId=${maven-staging-repository-id}" />
@@ -212,10 +235,14 @@
212235
<arg value="-Dgpg.passphrase=${gpg.passphrase}" />
213236
<!--<arg value="-Dsonatype-nexus-staging.username=${sonatype-nexus-staging.username}" />
214237
<arg value="-Dsonatype-nexus-staging.password=${sonatype-nexus-staging.password}" />-->
215-
</artifact:mvn>
238+
</java>
216239

217240
<!-- sign and deploy the sources artifact -->
218-
<artifact:mvn>
241+
<java classname="${mvn.mainclass}" classpathref="mvn.classpath" fork="true" failonerror="true">
242+
<jvmarg value="-Dclassworlds.conf=${env.M2_HOME}/bin/m2.conf" />
243+
<jvmarg value="-Dmaven.home=${env.M2_HOME}" />
244+
<jvmarg value="-Dmaven.multiModuleProjectDirectory=${basedir}" />
245+
219246
<arg value="org.apache.maven.plugins:maven-gpg-plugin:${maven-gpg-plugin.version}:sign-and-deploy-file" />
220247
<arg value="-Durl=${maven-staging-repository-url}" />
221248
<arg value="-DrepositoryId=${maven-staging-repository-id}" />
@@ -224,10 +251,14 @@
224251
<arg value="-Dclassifier=sources" />
225252
<arg value="-Pgpg" />
226253
<arg value="-Dgpg.passphrase=${gpg.passphrase}" />
227-
</artifact:mvn>
254+
</java>
228255

229256
<!-- sign and deploy the javadoc artifact -->
230-
<artifact:mvn>
257+
<java classname="${mvn.mainclass}" classpathref="mvn.classpath" fork="true" failonerror="true">
258+
<jvmarg value="-Dclassworlds.conf=${env.M2_HOME}/bin/m2.conf" />
259+
<jvmarg value="-Dmaven.home=${env.M2_HOME}" />
260+
<jvmarg value="-Dmaven.multiModuleProjectDirectory=${basedir}" />
261+
231262
<arg value="org.apache.maven.plugins:maven-gpg-plugin:${maven-gpg-plugin.version}:sign-and-deploy-file" />
232263
<arg value="-Durl=${maven-staging-repository-url}" />
233264
<arg value="-DrepositoryId=${maven-staging-repository-id}" />
@@ -236,7 +267,7 @@
236267
<arg value="-Dclassifier=javadoc" />
237268
<arg value="-Pgpg" />
238269
<arg value="-Dgpg.passphrase=${gpg.passphrase}" />
239-
</artifact:mvn>
270+
</java>
240271
</target>
241272

242273
</project>

doc/maven-sonatype.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,16 @@ see: https://central.sonatype.org/publish/generate-token/
3333
`(cd sqldump-logback && mvn clean deploy)`
3434
`(cd sqldump-mondrian && mvn clean deploy)`
3535

36+
* RELEASE:
37+
`(cd sqlmigrate && mvn clean javadoc:jar deploy -P release)`
38+
`(cd sqldump-jopendoc && mvn clean javadoc:jar deploy -P release)`
39+
`(cd sqldump-logback && mvn clean javadoc:jar deploy -P release)`
40+
`(cd sqldump-mondrian && mvn clean javadoc:jar deploy -P release)`
41+
3642

3743
4- release (if RELEASE version)
3844

39-
Go to <https://oss.sonatype.org/>, select 'staging repositories', select your repository (something like
45+
Go to <https://oss.sonatype.org/>, login, select 'staging repositories', select your repository (something like
4046
'comexampleapplication-1010'), review it then 'close' & 'release'
4147
see: http://central.sonatype.org/pages/releasing-the-deployment.html
4248

0 commit comments

Comments
 (0)