Unified · Split
| @@ -55,7 +55,7 @@ impl Cache { · 54 unmodified lines | ||
| 55 | 55 | .unwrap_or_else(|| crate::env::agent().into()) |
| 56 | 56 | }) |
| 57 | 57 | .to_owned(); |
| 58 | − ("agent", Some(git_protocol::fetch::agent(agent).into())) | |
| 58 | + ("agent", Some(git_protocol::agent(agent).into())) | |
| 59 | 59 | } |
| 60 | 60 | |
| 61 | 61 | pub(crate) fn personas(&self) -> &identity::Personas { |
| @@ -187,14 +187,14 @@ where · 186 unmodified lines | ||
| 187 | 187 | // Right now we block the executor by forcing this communication, but that only |
| 188 | 188 | // happens if the user didn't actually try to receive a pack, which consumes the |
| 189 | 189 | // connection in an async context. |
| 190 | − git_protocol::futures_lite::future::block_on(git_protocol::fetch::indicate_end_of_interaction( | |
| 190 | + git_protocol::futures_lite::future::block_on(git_protocol::indicate_end_of_interaction( | |
| 191 | 191 | &mut con.transport, |
| 192 | 192 | )) |
| 193 | 193 | .ok(); |
| 194 | 194 | } |
| 195 | 195 | #[cfg(not(feature = "async-network-client"))] |
| 196 | 196 | { |
| 197 | − git_protocol::fetch::indicate_end_of_interaction(&mut con.transport).ok(); | |
| 197 | + git_protocol::indicate_end_of_interaction(&mut con.transport).ok(); | |
| 198 | 198 | } |
| 199 | 199 | } |
| 200 | 200 | } |
| @@ -68,7 +68,7 @@ where · 67 unmodified lines | ||
| 68 | 68 | let handshake = &self.ref_map.handshake; |
| 69 | 69 | let protocol_version = handshake.server_protocol_version; |
| 70 | 70 | |
| 71 | − let fetch = git_protocol::fetch::Command::Fetch; | |
| 71 | + let fetch = git_protocol::Command::Fetch; | |
| 72 | 72 | let progress = &mut con.progress; |
| 73 | 73 | let repo = con.remote.repo; |
| 74 | 74 | let fetch_features = { |
| @@ -103,9 +103,7 @@ where · 28 unmodified lines | ||
| 103 | 103 | previous_response.as_ref(), |
| 104 | 104 | ) { |
| 105 | 105 | Ok(_) if arguments.is_empty() => { |
| 106 | − git_protocol::fetch::indicate_end_of_interaction(&mut con.transport) | |
| 107 | − .await | |
| 108 | − .ok(); | |
| 106 | + git_protocol::indicate_end_of_interaction(&mut con.transport).await.ok(); | |
| 109 | 107 | return Ok(Outcome { |
| 110 | 108 | ref_map: std::mem::take(&mut self.ref_map), |
| 111 | 109 | status: Status::NoChange, |
| @@ -113,9 +111,7 @@ where · 1 unmodified line | ||
| 113 | 111 | } |
| 114 | 112 | Ok(is_done) => is_done, |
| 115 | 113 | Err(err) => { |
| 116 | − git_protocol::fetch::indicate_end_of_interaction(&mut con.transport) | |
| 117 | − .await | |
| 118 | − .ok(); | |
| 114 | + git_protocol::indicate_end_of_interaction(&mut con.transport).await.ok(); | |
| 119 | 115 | return Err(err.into()); |
| 120 | 116 | } |
| 121 | 117 | }; |
| @@ -169,9 +165,7 @@ where · 47 unmodified lines | ||
| 169 | 165 | }; |
| 170 | 166 | |
| 171 | 167 | if matches!(protocol_version, git_protocol::transport::Protocol::V2) { |
| 172 | − git_protocol::fetch::indicate_end_of_interaction(&mut con.transport) | |
| 173 | − .await | |
| 174 | − .ok(); | |
| 168 | + git_protocol::indicate_end_of_interaction(&mut con.transport).await.ok(); | |
| 175 | 169 | } |
| 176 | 170 | |
| 177 | 171 | let update_refs = refs::update( |
| @@ -25,7 +25,7 @@ pub enum Error { · 24 unmodified lines | ||
| 25 | 25 | #[error("The object format {format:?} as used by the remote is unsupported")] |
| 26 | 26 | UnknownObjectFormat { format: BString }, |
| 27 | 27 | #[error(transparent)] |
| 28 | − ListRefs(#[from] git_protocol::fetch::refs::Error), | |
| 28 | + ListRefs(#[from] git_protocol::ls_refs::Error), | |
| 29 | 29 | #[error(transparent)] |
| 30 | 30 | Transport(#[from] git_protocol::transport::client::Error), |
| 31 | 31 | #[error(transparent)] |
| @@ -80,7 +80,7 @@ where · 48 unmodified lines | ||
| 80 | 80 | #[git_protocol::maybe_async::maybe_async] |
| 81 | 81 | pub async fn ref_map(mut self, options: Options) -> Result<fetch::RefMap, Error> { |
| 82 | 82 | let res = self.ref_map_inner(options).await; |
| 83 | − git_protocol::fetch::indicate_end_of_interaction(&mut self.transport) | |
| 83 | + git_protocol::indicate_end_of_interaction(&mut self.transport) | |
| 84 | 84 | .await |
| 85 | 85 | .ok(); |
| 86 | 86 | res |
| @@ -181,9 +181,8 @@ where · 94 unmodified lines | ||
| 181 | 181 | None => { |
| 182 | 182 | let specs = &self.remote.fetch_specs; |
| 183 | 183 | let agent_feature = self.remote.repo.config.user_agent_tuple(); |
| 184 | − git_protocol::fetch::refs( | |
| 184 | + git_protocol::ls_refs( | |
| 185 | 185 | &mut self.transport, |
| 186 | − outcome.server_protocol_version, | |
| 187 | 186 | &outcome.capabilities, |
| 188 | 187 | move |_capabilities, arguments, features| { |
| 189 | 188 | features.push(agent_feature); |
| @@ -201,7 +200,7 @@ where · 11 unmodified lines | ||
| 201 | 200 | } |
| 202 | 201 | } |
| 203 | 202 | } |
| 204 | − Ok(git_protocol::fetch::delegate::LsRefsAction::Continue) | |
| 203 | + Ok(git_protocol::ls_refs::Action::Continue) | |
| 205 | 204 | }, |
| 206 | 205 | &mut self.progress, |
| 207 | 206 | ) |