Notice the user when the --mint, --bpf-program, or --clone arguments are ignored

(cherry picked from commit 59c19d9fbf)
This commit is contained in:
Michael Vines
2021-03-17 11:01:49 -07:00
parent f528cda832
commit af45efb62c
2 changed files with 23 additions and 2 deletions

View File

@@ -354,6 +354,18 @@ fn main() {
});
}
if TestValidatorGenesis::ledger_exists(&ledger_path) {
for (name, long) in &[
("bpf_program", "--bpf-program"),
("clone_account", "--clone"),
("mint_address", "--mint"),
] {
if matches.is_present(name) {
println!("{} argument ignored, ledger already exists", long);
}
}
}
let mut genesis = TestValidatorGenesis::default();
admin_rpc_service::run(