diff --git a/README.md b/README.md index 8e8d8992e..1f23ee4a7 100644 --- a/README.md +++ b/README.md @@ -33,13 +33,11 @@ critical fixes to the [3.12.x branch][okhttp_312x] through December 31, 2020. Download -------- -Download [the latest JAR][okhttp_latest_jar] or configure this dependency: - ```kotlin implementation("com.squareup.okhttp3:okhttp:3.14.2") ``` -Snapshots of the development version are available in [Sonatype's `snapshots` repository][snap]. +Snapshot builds are [available][snap]. MockWebServer @@ -51,8 +49,7 @@ MockWebServer coupling with OkHttp is essential for proper testing of HTTP/2 so ### Download -Download [the latest JAR][mockwebserver_latest_jar] or configure this dependency: -```xml +```kotlin testImplementation("com.squareup.okhttp3:mockwebserver:3.14.2") ``` @@ -81,9 +78,7 @@ License [conscrypt]: https://github.com/google/conscrypt/ - [mockwebserver_latest_jar]: https://search.maven.org/remote_content?g=com.squareup.okhttp3&a=mockwebserver&v=LATEST [okhttp_312x]: https://github.com/square/okhttp/tree/okhttp_3.12.x - [okhttp_latest_jar]: https://search.maven.org/remote_content?g=com.squareup.okhttp3&a=okhttp&v=LATEST [okio]: https://github.com/square/okio/ [snap]: https://oss.sonatype.org/content/repositories/snapshots/ [tls_history]: https://github.com/square/okhttp/wiki/TLS-Configuration-History diff --git a/RELEASING.md b/RELEASING.md new file mode 100644 index 000000000..9d7e1d5db --- /dev/null +++ b/RELEASING.md @@ -0,0 +1,47 @@ +Releasing +========= + +1. Update `CHANGELOG.md`. + +2. Set versions: + + ``` + export RELEASE_VERSION=X.Y.Z + export NEXT_VERSION=X.Y.Z-SNAPSHOT + ``` + +3. Update, build, and upload: + + ``` + sed -i "" \ + "s/VERSION_NAME=.*/VERSION_NAME=$RELEASE_VERSION/g" \ + gradle.properties + sed -i "" \ + "s/\"com.squareup.okhttp3:\([^\:]*\):[^\"]*\"/\"com.squareup.okhttp3:\1:$RELEASE_VERSION\"/g" \ + `find . -name "README.md"` + ./gradlew clean uploadArchives + ``` + +4. Visit [Sonatype Nexus](https://oss.sonatype.org/) to promote the artifact. Or drop it if there is a problem! + +5. Tag the release, prepare for the next one, and push to GitHub. + + ``` + git commit -am "Prepare for release $RELEASE_VERSION." + git tag -a parent-$RELEASE_VERSION -m "Version $RELEASE_VERSION" + sed -i "" \ + "s/VERSION_NAME=.*/VERSION_NAME=$NEXT_VERSION/g" \ + gradle.properties + git commit -am "Prepare next development version." + git push && git push --tags + ``` + + +Prerequisites +------------- + +In `~/.gradle/gradle.properties`, set the following: + + * `SONATYPE_NEXUS_USERNAME` - Sonatype username for releasing to `com.squareup`. + * `SONATYPE_NEXUS_PASSWORD` - Sonatype password for releasing to `com.squareup`. + diff --git a/mockwebserver/README.md b/mockwebserver/README.md index 73503bb6d..f19837491 100644 --- a/mockwebserver/README.md +++ b/mockwebserver/README.md @@ -140,19 +140,8 @@ server.setDispatcher(dispatcher); ### Download -Get MockWebServer via Maven: -```xml - - com.squareup.okhttp3 - mockwebserver - (insert latest version) - test - -``` - -or via Gradle -```groovy -testImplementation 'com.squareup.okhttp3:mockwebserver:(insert latest version)' +```kotlin +testImplementation("com.squareup.okhttp3:mockwebserver:3.14.2") ``` ### License diff --git a/okhttp-dnsoverhttps/README.md b/okhttp-dnsoverhttps/README.md index 30132b47c..5aea64e7e 100644 --- a/okhttp-dnsoverhttps/README.md +++ b/okhttp-dnsoverhttps/README.md @@ -3,3 +3,9 @@ OkHttp DNS over HTTPS Implementation This module is an experimental implementation of DNS over HTTPS using OkHttp. API is not considered stable and may change at any time. + +### Download + +```kotlin +testImplementation("com.squareup.okhttp3:okhttp-dnsoverhttps:3.14.2") +``` diff --git a/okhttp-logging-interceptor/README.md b/okhttp-logging-interceptor/README.md index fae2f6e6c..5da532419 100644 --- a/okhttp-logging-interceptor/README.md +++ b/okhttp-logging-interceptor/README.md @@ -36,18 +36,8 @@ logging.redactHeader("Cookie"); Download -------- -Get via Maven: -```xml - - com.squareup.okhttp3 - logging-interceptor - (insert latest version) - -``` - -or via Gradle -```groovy -implementation 'com.squareup.okhttp3:logging-interceptor:(insert latest version)' +```kotlin +implementation("com.squareup.okhttp3:logging-interceptor:3.14.2") ``` diff --git a/okhttp-sse/README.md b/okhttp-sse/README.md index 2b1bc4283..d8f570a19 100644 --- a/okhttp-sse/README.md +++ b/okhttp-sse/README.md @@ -3,3 +3,9 @@ OkHttp Server-Sent Events Experimental support for server-sent events. API is not considered stable and may change at any time. + +### Download + +```kotlin +testImplementation("com.squareup.okhttp3:okhttp-sse:3.14.2") +``` diff --git a/okhttp-tls/README.md b/okhttp-tls/README.md index 2ecaa5c3b..15fe88620 100644 --- a/okhttp-tls/README.md +++ b/okhttp-tls/README.md @@ -226,18 +226,8 @@ clients use `HeldCertificate.Builder.rsa2048()`. Download -------- -Get via Maven: -```xml - - com.squareup.okhttp3 - okhttp-tls - (insert latest version) - -``` - -or via Gradle -```groovy -implementation 'com.squareup.okhttp3:okhttp-tls:(insert latest version)' +```kotlin +implementation("com.squareup.okhttp3:okhttp-tls:3.14.2") ``` [held_certificate]: http://square.github.io/okhttp/3.x/okhttp-tls/okhttp3/tls/HeldCertificate.html diff --git a/okhttp-urlconnection/README.md b/okhttp-urlconnection/README.md new file mode 100644 index 000000000..1a2234c30 --- /dev/null +++ b/okhttp-urlconnection/README.md @@ -0,0 +1,10 @@ +OkHttp URLConnection +==================== + +This module integrates OkHttp with `Authenticator` and `CookieHandler` from `java.net`. + +### Download + +```kotlin +testImplementation("com.squareup.okhttp3:okhttp-urlconnection:3.14.2") +```