mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-22 23:04:33 +00:00
Rollup merge of #104865 - pratushrai0309:bootstrap, r=jyn514
Don't overwrite local changes when updating submodules Fixes https://github.com/rust-lang/rust/issues/103485
This commit is contained in:
commit
3d64420fa9
@ -647,9 +647,10 @@ impl Build {
|
||||
if !update(true).status().map_or(false, |status| status.success()) {
|
||||
self.run(&mut update(false));
|
||||
}
|
||||
|
||||
self.run(Command::new("git").args(&["stash", "push"]).current_dir(&absolute_path));
|
||||
self.run(Command::new("git").args(&["reset", "-q", "--hard"]).current_dir(&absolute_path));
|
||||
self.run(Command::new("git").args(&["clean", "-qdfx"]).current_dir(absolute_path));
|
||||
self.run(Command::new("git").args(&["clean", "-qdfx"]).current_dir(&absolute_path));
|
||||
self.run(Command::new("git").args(&["stash", "pop"]).current_dir(absolute_path));
|
||||
}
|
||||
|
||||
/// If any submodule has been initialized already, sync it unconditionally.
|
||||
|
Loading…
Reference in New Issue
Block a user