File tree Expand file tree Collapse file tree 6 files changed +12
-6
lines changed Expand file tree Collapse file tree 6 files changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ use super::{util, Error};
2
2
3
3
/// A utility to deal with the cyclic dependency between the ref store and the configuration. The ref-store needs the
4
4
/// object hash kind, and the configuration needs the current branch name to resolve conditional includes with `onbranch`.
5
- #[ allow( dead_code) ]
6
5
pub ( crate ) struct StageOne {
7
6
pub git_dir_config : git_config:: File < ' static > ,
8
7
pub buf : Vec < u8 > ,
Original file line number Diff line number Diff line change @@ -90,7 +90,6 @@ impl Default for Options {
90
90
}
91
91
92
92
#[ derive( Default , Clone ) ]
93
- #[ allow( dead_code) ]
94
93
pub ( crate ) struct EnvironmentOverrides {
95
94
/// An override of the worktree typically from the environment, and overrides even worktree dirs set as parameter.
96
95
///
Original file line number Diff line number Diff line change @@ -136,7 +136,12 @@ pub mod to_map {
136
136
local : m. rhs . map ( |c| c. into_owned ( ) ) ,
137
137
} )
138
138
. collect ( ) ;
139
- Ok ( fetch:: RefMap { mappings, fixes } )
139
+ Ok ( fetch:: RefMap {
140
+ mappings,
141
+ fixes,
142
+ remote_refs : remote. refs ,
143
+ handshake : remote. outcome ,
144
+ } )
140
145
}
141
146
}
142
147
}
Original file line number Diff line number Diff line change 1
1
use crate :: Remote ;
2
2
3
3
pub ( crate ) struct HandshakeWithRefs {
4
- #[ allow( dead_code) ]
5
4
outcome : git_protocol:: fetch:: handshake:: Outcome ,
6
5
refs : Vec < git_protocol:: fetch:: Ref > ,
7
6
}
Original file line number Diff line number Diff line change @@ -37,6 +37,12 @@ pub mod fetch {
37
37
pub mappings : Vec < Mapping > ,
38
38
/// Information about the fixes applied to the `mapping` due to validation and sanitization.
39
39
pub fixes : Vec < git_refspec:: match_group:: validate:: Fix > ,
40
+ /// All refs advertised by the remote.
41
+ pub remote_refs : Vec < git_protocol:: fetch:: Ref > ,
42
+ /// Additional information provided by the server as part of the handshake.
43
+ ///
44
+ /// Note that the `refs` field is always `None` as the refs are placed in `remote_refs`.
45
+ pub handshake : git_protocol:: fetch:: handshake:: Outcome ,
40
46
}
41
47
42
48
/// Either an object id that the remote has or the matched remote ref itself.
Original file line number Diff line number Diff line change 1
- #![ allow( dead_code, unused_variables) ]
2
-
3
1
use std:: { borrow:: Cow , collections:: BTreeMap , convert:: TryFrom } ;
4
2
5
3
use crate :: bstr:: { BStr , BString , ByteSlice } ;
You can’t perform that action at this time.
0 commit comments