Initial stabilization #1
1 changed files with 6 additions and 1 deletions
commit
af385b3f82
|
|
@ -6,7 +6,7 @@ use isahc::{
|
||||||
HttpClient, HttpClientBuilder, Request,
|
HttpClient, HttpClientBuilder, Request,
|
||||||
auth::{Authentication, Credentials},
|
auth::{Authentication, Credentials},
|
||||||
config::Configurable,
|
config::Configurable,
|
||||||
http::{Method, StatusCode},
|
http::{Method, StatusCode, header},
|
||||||
};
|
};
|
||||||
use secrecy::{ExposeSecret, SecretString};
|
use secrecy::{ExposeSecret, SecretString};
|
||||||
use tar::{Builder, HeaderMode};
|
use tar::{Builder, HeaderMode};
|
||||||
|
|
@ -141,6 +141,11 @@ impl Client {
|
||||||
let request = Request::builder()
|
let request = Request::builder()
|
||||||
.uri(uri)
|
.uri(uri)
|
||||||
.method(Method::PATCH)
|
.method(Method::PATCH)
|
||||||
|
.header(header::CONTENT_TYPE, "application/octet-stream")
|
||||||
|
.header(
|
||||||
|
header::CONTENT_RANGE,
|
||||||
|
format!("bytes {}-{}/*", 0, archive.len()),
|
||||||
|
)
|
||||||
.body(archive)
|
.body(archive)
|
||||||
.context("building the request")?;
|
.context("building the request")?;
|
||||||
let mut response = self
|
let mut response = self
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue