mirror of
https://github.com/c-cube/ezcurl.git
synced 2026-01-21 16:56:42 -05:00
prepare for 0.3
This commit is contained in:
parent
2c756473dd
commit
aa5474167f
6 changed files with 31 additions and 20 deletions
23
CHANGELOG.md
23
CHANGELOG.md
|
|
@ -1,27 +1,38 @@
|
||||||
## 0.2.4
|
|
||||||
|
# 0.3
|
||||||
|
|
||||||
|
- Provide seek function when uploading from string
|
||||||
|
- make `CURLOPT_NOSIGNAL=false` the default; simplify
|
||||||
|
- Expose underlying no signal in a global setting
|
||||||
|
- implement `http_stream`
|
||||||
|
- feat: add `Ezcurl.Cookies` module, get/set/transfer them
|
||||||
|
|
||||||
|
- breaking: wrap Curl.t in record
|
||||||
|
|
||||||
|
# 0.2.4
|
||||||
|
|
||||||
- fix: global initialization logic is now hidden behind a mutex
|
- fix: global initialization logic is now hidden behind a mutex
|
||||||
* depend on `thread`
|
* depend on `thread`
|
||||||
|
|
||||||
## 0.2.3
|
# 0.2.3
|
||||||
|
|
||||||
- fix: workaround servers which do not understand "Expect" header
|
- fix: workaround servers which do not understand "Expect" header
|
||||||
- fix: correctly set size of payload for POST
|
- fix: correctly set size of payload for POST
|
||||||
- make sure to setup 'PUT" correctly
|
- make sure to setup 'PUT" correctly
|
||||||
- allow POST with non-form data
|
- allow POST with non-form data
|
||||||
|
|
||||||
## 0.2.2
|
# 0.2.2
|
||||||
|
|
||||||
- fix: do not reset client if passed as argument
|
- fix: do not reset client if passed as argument
|
||||||
|
|
||||||
## 0.2.1
|
# 0.2.1
|
||||||
|
|
||||||
- fix setting of headers
|
- fix setting of headers
|
||||||
|
|
||||||
## 0.2
|
# 0.2
|
||||||
|
|
||||||
- add default user agent
|
- add default user agent
|
||||||
|
|
||||||
## 0.1
|
# 0.1
|
||||||
|
|
||||||
- initial release
|
- initial release
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
(name ezcurl)
|
(name ezcurl)
|
||||||
|
|
||||||
(version 0.2.4)
|
(version 0.3)
|
||||||
|
|
||||||
(generate_opam_files true)
|
(generate_opam_files true)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
# This file is generated by dune, edit dune-project instead
|
# This file is generated by dune, edit dune-project instead
|
||||||
opam-version: "2.0"
|
opam-version: "2.0"
|
||||||
version: "0.2.4"
|
version: "0.3"
|
||||||
synopsis: "Friendly wrapper around OCurl, Lwt version"
|
synopsis: "Friendly wrapper around OCurl, Lwt version"
|
||||||
maintainer: ["simon.cruanes.2007@m4x.org"]
|
maintainer: ["simon.cruanes.2007@m4x.org"]
|
||||||
authors: ["Simon Cruanes"]
|
authors: ["Simon Cruanes"]
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
# This file is generated by dune, edit dune-project instead
|
# This file is generated by dune, edit dune-project instead
|
||||||
opam-version: "2.0"
|
opam-version: "2.0"
|
||||||
version: "0.2.4"
|
version: "0.3"
|
||||||
synopsis: "Friendly wrapper around OCurl"
|
synopsis: "Friendly wrapper around OCurl"
|
||||||
maintainer: ["simon.cruanes.2007@m4x.org"]
|
maintainer: ["simon.cruanes.2007@m4x.org"]
|
||||||
authors: ["Simon Cruanes"]
|
authors: ["Simon Cruanes"]
|
||||||
|
|
|
||||||
|
|
@ -261,7 +261,7 @@ module type S = sig
|
||||||
@param headers headers of the query *)
|
@param headers headers of the query *)
|
||||||
|
|
||||||
(** Push-stream of bytes
|
(** Push-stream of bytes
|
||||||
@since NEXT_RELEASE *)
|
@since 0.3 *)
|
||||||
class type input_stream = object
|
class type input_stream = object
|
||||||
method on_close : unit -> unit
|
method on_close : unit -> unit
|
||||||
method on_input : bytes -> int -> int -> unit
|
method on_input : bytes -> int -> int -> unit
|
||||||
|
|
@ -280,7 +280,7 @@ module type S = sig
|
||||||
unit ->
|
unit ->
|
||||||
(unit response, Curl.curlCode * string) result io
|
(unit response, Curl.curlCode * string) result io
|
||||||
(** HTTP call via cURL, with a streaming response body.
|
(** HTTP call via cURL, with a streaming response body.
|
||||||
@since NEXT_RELEASE *)
|
@since 0.3 *)
|
||||||
|
|
||||||
val get :
|
val get :
|
||||||
?tries:int ->
|
?tries:int ->
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ end
|
||||||
|
|
||||||
type t = private { curl: Curl.t } [@@unboxed]
|
type t = private { curl: Curl.t } [@@unboxed]
|
||||||
(** A client, i.e. a cURL instance. The wrapping record has been present since
|
(** A client, i.e. a cURL instance. The wrapping record has been present since
|
||||||
NEXT_RELEASE *)
|
0.3 *)
|
||||||
|
|
||||||
val make :
|
val make :
|
||||||
?set_opts:(Curl.t -> unit) ->
|
?set_opts:(Curl.t -> unit) ->
|
||||||
|
|
@ -29,10 +29,10 @@ val make :
|
||||||
@param set_opts called before returning the client, to set options
|
@param set_opts called before returning the client, to set options
|
||||||
@param cookiejar_file
|
@param cookiejar_file
|
||||||
if provided, tell curl to use the given file path to store/load cookies
|
if provided, tell curl to use the given file path to store/load cookies
|
||||||
(since NEXT_RELEASE)
|
(since 0.3)
|
||||||
@param enable_session_cookies
|
@param enable_session_cookies
|
||||||
if provided, enable cookie handling in curl so it store/load cookies
|
if provided, enable cookie handling in curl so it store/load cookies
|
||||||
(since NEXT_RELEASE) *)
|
(since 0.3) *)
|
||||||
|
|
||||||
val delete : t -> unit
|
val delete : t -> unit
|
||||||
(** Delete the client. It cannot be used anymore. *)
|
(** Delete the client. It cannot be used anymore. *)
|
||||||
|
|
@ -43,21 +43,21 @@ val with_client : ?set_opts:(Curl.t -> unit) -> (t -> 'a) -> 'a
|
||||||
val set_no_signal : bool -> unit
|
val set_no_signal : bool -> unit
|
||||||
(** Set no_signal default value for each new client instance. Default is [true].
|
(** Set no_signal default value for each new client instance. Default is [true].
|
||||||
See [CURLOPT_NOSIGNAL].
|
See [CURLOPT_NOSIGNAL].
|
||||||
@since NEXT_RELEASE *)
|
@since 0.3 *)
|
||||||
|
|
||||||
(** Cookie handling.
|
(** Cookie handling.
|
||||||
|
|
||||||
@since NEXT_RELEASE *)
|
@since 0.3 *)
|
||||||
module Cookies : sig
|
module Cookies : sig
|
||||||
val flush_cookiejar : t -> unit
|
val flush_cookiejar : t -> unit
|
||||||
(** If [cookiejar_file] was provided in {!make}, this flushes the current set
|
(** If [cookiejar_file] was provided in {!make}, this flushes the current set
|
||||||
of cookies to the provided file.
|
of cookies to the provided file.
|
||||||
@since NEXT_RELEASE *)
|
@since 0.3 *)
|
||||||
|
|
||||||
val reload_cookiejar : t -> unit
|
val reload_cookiejar : t -> unit
|
||||||
(** If [cookiejar_file] was provided in {!make}, this reloads cookies from the
|
(** If [cookiejar_file] was provided in {!make}, this reloads cookies from the
|
||||||
provided file.
|
provided file.
|
||||||
@since NEXT_RELEASE *)
|
@since 0.3 *)
|
||||||
|
|
||||||
val get_cookies : t -> string list
|
val get_cookies : t -> string list
|
||||||
(** Get cookie list (in netscape format) *)
|
(** Get cookie list (in netscape format) *)
|
||||||
|
|
@ -164,7 +164,7 @@ module type S = sig
|
||||||
@param headers headers of the query *)
|
@param headers headers of the query *)
|
||||||
|
|
||||||
(** Push-based stream of bytes
|
(** Push-based stream of bytes
|
||||||
@since NEXT_RELEASE *)
|
@since 0.3 *)
|
||||||
class type input_stream = object
|
class type input_stream = object
|
||||||
method on_close : unit -> unit
|
method on_close : unit -> unit
|
||||||
method on_input : bytes -> int -> int -> unit
|
method on_input : bytes -> int -> int -> unit
|
||||||
|
|
@ -185,7 +185,7 @@ module type S = sig
|
||||||
(** HTTP call via cURL, with a streaming response body. The body is given to
|
(** HTTP call via cURL, with a streaming response body. The body is given to
|
||||||
[write_into] by chunks, then [write_into#on_close ()] is called and the
|
[write_into] by chunks, then [write_into#on_close ()] is called and the
|
||||||
response is returned.
|
response is returned.
|
||||||
@since NEXT_RELEASE *)
|
@since 0.3 *)
|
||||||
|
|
||||||
val get :
|
val get :
|
||||||
?tries:int ->
|
?tries:int ->
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue