File tree Expand file tree Collapse file tree 4 files changed +6
-4
lines changed Expand file tree Collapse file tree 4 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -101,4 +101,8 @@ impl GitInfo {
101
101
}
102
102
version
103
103
}
104
+
105
+ pub fn is_git ( & self ) -> bool {
106
+ self . inner . is_some ( )
107
+ }
104
108
}
Original file line number Diff line number Diff line change @@ -623,7 +623,7 @@ pub fn plain_source_tarball(build: &Build) {
623
623
write_file ( & plain_dst_src. join ( "version" ) , build. rust_version ( ) . as_bytes ( ) ) ;
624
624
625
625
// If we're building from git sources, we need to vendor a complete distribution.
626
- if build. src_is_git {
626
+ if build. rust_info . is_git ( ) {
627
627
// Get cargo-vendor installed, if it isn't already.
628
628
let mut has_cargo_vendor = false ;
629
629
let mut cmd = Command :: new ( & build. initial_cargo ) ;
Original file line number Diff line number Diff line change @@ -183,7 +183,6 @@ pub struct Build {
183
183
cxx : HashMap < String , gcc:: Tool > ,
184
184
crates : HashMap < String , Crate > ,
185
185
is_sudo : bool ,
186
- src_is_git : bool ,
187
186
ci_env : CiEnv ,
188
187
delayed_failures : Cell < usize > ,
189
188
}
@@ -262,7 +261,6 @@ impl Build {
262
261
lldb_version : None ,
263
262
lldb_python_dir : None ,
264
263
is_sudo : is_sudo,
265
- src_is_git : src_is_git,
266
264
ci_env : CiEnv :: current ( ) ,
267
265
delayed_failures : Cell :: new ( 0 ) ,
268
266
}
Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ pub fn check(build: &mut Build) {
80
80
let mut cmd_finder = Finder :: new ( ) ;
81
81
// If we've got a git directory we're gona need git to update
82
82
// submodules and learn about various other aspects.
83
- if build. src_is_git {
83
+ if build. rust_info . is_git ( ) {
84
84
cmd_finder. must_have ( "git" ) ;
85
85
}
86
86
You can’t perform that action at this time.
0 commit comments