diff --git a/CHANGELOG.md b/CHANGELOG.md index c741f5d..ba1f195 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,11 @@ +## 0.7.0 + This is a feature release + +* [SERVER-1556](https://tickets.puppetlabs.com/browse/SERVER-1556) Add + puppetlabs/clj-i18n support to clj-http-client. +* Pass the global i18n locale binding in the "accept-language" header of Clojure + client requests. + ## 0.6.0 This is a feature and maintenance release diff --git a/doc/clojure-client.md b/doc/clojure-client.md index 6186f00..d700c2e 100644 --- a/doc/clojure-client.md +++ b/doc/clojure-client.md @@ -88,7 +88,9 @@ Each request function takes one argument, `url`, which is the URL against which your HTTP request. Each request function also has a two-arity version with an extra parameter, `options`, which is a map containing options for the HTTP request. These options are as follows: -* `:headers`: optional; a map of headers +* `:headers`: optional; a map of headers. By default an 'accept-language' header + with a value of `puppetlabs.core.i18n/user-locale` will be added to the + request. * `:body`: optional; may be a String or any type supported by clojure's reader * `:decompress-body`: optional; if `true`, an 'accept-encoding' header with a value of 'gzip, deflate' will be added to the request, and the response will be diff --git a/project.clj b/project.clj index 3068472..da9ac57 100644 --- a/project.clj +++ b/project.clj @@ -1,8 +1,9 @@ (def ks-version "1.3.0") (def tk-version "1.5.1") (def tk-jetty-version "1.5.0") +(def i18n-version "0.4.3") -(defproject puppetlabs/http-client "0.6.1-SNAPSHOT" +(defproject puppetlabs/http-client "0.7.0-SNAPSHOT" :description "HTTP client wrapper" :license {:name "Apache License, Version 2.0" :url "http://www.apache.org/licenses/LICENSE-2.0.html"} @@ -22,7 +23,7 @@ [io.dropwizard.metrics/metrics-core "3.1.2"] [puppetlabs/ssl-utils "0.8.1"] - [puppetlabs/i18n "0.4.3"]] + [puppetlabs/i18n ~i18n-version]] :source-paths ["src/clj"] :java-source-paths ["src/java"] @@ -53,4 +54,4 @@ :deploy-via :lein-deploy} :plugins [[lein-release "1.0.5" :exclusions [org.clojure/clojure]] - [puppetlabs/i18n "0.4.3"]]) + [puppetlabs/i18n ~i18n-version]])