Skip to content

Commit b46d3ac

Browse files
committed
Always clean and rebuild godot, for now
1 parent 1e8461e commit b46d3ac

1 file changed

Lines changed: 4 additions & 15 deletions

File tree

gui/rust/src/bin/gui_tool.rs

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -18,21 +18,12 @@ enum Action {
1818
}
1919

2020
fn main() {
21-
let mut args = env::args().skip(1).collect::<Vec<String>>();
22-
let mut clean = false;
21+
let args = env::args().skip(1).collect::<Vec<String>>();
2322

2423
// Minimal arg parsing to avoid extra deps.
2524
// Usage:
26-
// gui-tool [--clean] [build-and-export|build-lib|export|print-binary-path]
25+
// gui-tool [build-and-export|build-lib|export|print-binary-path]
2726
// Defaults to build-and-export.
28-
args.retain(|a| {
29-
if a == "--clean" {
30-
clean = true;
31-
false
32-
} else {
33-
true
34-
}
35-
});
3627

3728
let action = match args.get(0).map(|s| s.as_str()) {
3829
None => Action::BuildAndExport,
@@ -42,16 +33,14 @@ fn main() {
4233
Some("print-binary-path") => Action::PrintBinaryPath,
4334
Some(other) => {
4435
eprintln!(
45-
"Unknown subcommand: {}\nUsage: gui-tool [--clean] [build-and-export|build-lib|export|print-binary-path]",
36+
"Unknown subcommand: {}\nUsage: gui-tool [build-and-export|build-lib|export|print-binary-path]",
4637
other
4738
);
4839
std::process::exit(2);
4940
}
5041
};
5142

52-
if clean {
53-
clean_build_dirs();
54-
}
43+
clean_build_dirs();
5544

5645
let is_debug_build = cfg!(debug_assertions);
5746
match action {

0 commit comments

Comments
 (0)