Skip to content

Commit 39c1af7

Browse files
committed
adapt to changes in git-repository
1 parent e60d079 commit 39c1af7

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

gitoxide-core/src/net.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
use std::str::FromStr;
22

3-
pub fn agent() -> &'static str {
4-
concat!("oxide-", env!("CARGO_PKG_VERSION"))
5-
}
6-
73
#[derive(Eq, PartialEq, Debug)]
84
pub enum Protocol {
95
V1,

gitoxide-core/src/pack/receive.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ impl<W> protocol::fetch::DelegateBlocking for CloneDelegate<W> {
116116
mod blocking_io {
117117
use std::{io, io::BufRead, path::PathBuf};
118118

119+
use git_repository as git;
119120
use git_repository::{
120121
bstr::BString,
121122
protocol,
@@ -173,7 +174,7 @@ mod blocking_io {
173174
protocol::credentials::builtin,
174175
progress,
175176
protocol::FetchConnection::TerminateOnSuccessfulCompletion,
176-
crate::net::agent(),
177+
git::env::agent(),
177178
)?;
178179
Ok(())
179180
}
@@ -198,6 +199,7 @@ mod async_io {
198199

199200
use super::{print, receive_pack_blocking, write_raw_refs, CloneDelegate, Context};
200201
use crate::{net, OutputFormat};
202+
use git_repository as git;
201203

202204
#[async_trait(?Send)]
203205
impl<W: io::Write + Send + 'static> protocol::fetch::Delegate for CloneDelegate<W> {
@@ -247,7 +249,7 @@ mod async_io {
247249
protocol::credentials::builtin,
248250
progress,
249251
protocol::FetchConnection::TerminateOnSuccessfulCompletion,
250-
crate::net::agent(),
252+
git::env::agent(),
251253
))
252254
})
253255
.await?;

0 commit comments

Comments
 (0)