@@ -31,13 +31,16 @@ Details and background information can be read on our [ePages Developer Blog](ht
3131<!-- /TOC -->
3232## Contents
3333
34- This repository consists of four projects
34+ This repository consists of two libraries:
3535
3636* ` restdocs-wiremock ` : The library to extend Spring REST Docs with WireMock stub snippet generation.
37- * ` restdocs-server ` : A sample server documenting its REST API (i.e. the Spring REST Docs "notes" example).
38- Besides producing human-readable documentation it will also generate JSON snippets to be used as stubs for WireMock.
3937* ` wiremock-spring-boot-starter ` : A spring boot starter which adds a ` WireMockServer ` to your client's ApplicationContext for integration testing.
4038 This is optional, but highly recommended when verifying your client contract in a SpringBootTest.
39+
40+ And two sample projects:
41+
42+ * ` restdocs-server ` : A sample server documenting its REST API (i.e. the Spring REST Docs "notes" example).
43+ Besides producing human-readable documentation it will also generate JSON snippets to be used as stubs for WireMock.
4144* ` restdocs-client ` : A sample client using the server API, with integration testing its client contract against the stubs provided via WireMock.
4245
4346
@@ -334,6 +337,17 @@ public class MyTest {
334337
335338## Building from source
336339
340+ This project uses JDK 8.
341+ JDK 8 can be used via [SDKMAN!](https://sdkman.io/).
342+
343+ ```
344+ # (a) not installed, yet
345+ sdk install java 8.0.282.j9-adpt
346+
347+ # (b) already installed
348+ sdk use java 8.0.282.j9-adpt
349+ ```
350+
337351Please execute at least step 1 + 2 if before importing restdocs-wiremock into your IDE.
338352
3393531. Publish the current restdocs-wiremock library code into your local maven repository.
@@ -359,17 +373,37 @@ Please execute at least step 1 + 2 if before importing restdocs-wiremock into yo
359373
360374## Publishing
361375
362- This project makes use of the [axion-release-plugin](https://github.com/allegro/axion-release-plugin)
363- and publishing is automated in travis, when a new release is tagged in git.
364-
365- Locally you should be able to create a new release by running the `release` task on gradle. A successful
366- travis build of this tag should finally end up on [bintray](https://bintray.com/epages/maven/restdocs-wiremock/).
376+ Given that the `master` branch on the upstream repository is in the state from which you want to create a release, execute the following steps:
367377
368378```shell
369- ./gradlew clean build release
379+ git checkout master
380+ git pull upstream master
381+
382+ # Print current version to the terminal
383+ ./gradlew currentVersion
384+
385+ # (a) Release new patch version
386+ ./gradlew release -Prelease.versionIncrementer=incrementPatch
387+
388+ # (b) Release new minor version
389+ ./gradlew release -Prelease.versionIncrementer=incrementMajor
390+
391+ ## (c) Release new major version
392+ ./gradlew release -Prelease.versionIncrementer=incrementMajor
393+
394+ # Print current version to the terminal
395+ ./gradlew currentVersion
370396```
371397
398+ TravisCI will then take care to call the Gradle tasks which upload the release to Sonatype.
399+ A new staging repository will be create at [oss.sonatype.org](https://oss.sonatype.org/#stagingRepositories).
400+ You need to login there, go to the latest staging repository, and then close and release the repository in the Sonatype UI.
401+
402+ (Once this process is working reliably we can also automate the final manual steps.)
403+
372404## Other resources
373405
406+ - [gradle-nexus/publish-plugin](https://github.com/gradle-nexus/publish-plugin)
407+ - [allegro/axion-release-plugin](https://axion-release-plugin.readthedocs.io)
408+ - [Maven Publish Plugin](https://docs.gradle.org/current/userguide/publishing_maven.html)
374409- A similar approach is taken by [Spring Cloud Contract](https://cloud.spring.io/spring-cloud-contract/)
375-
0 commit comments