Skip to content

Commit

Permalink
feat(bind): option to skip Cargo.toml from consistency checks
Browse files Browse the repository at this point in the history
  • Loading branch information
meetmangukiya committed May 23, 2022
1 parent 84221b1 commit 923d19e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion cli/src/cmd/forge/bind.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ pub struct BindArgs {
#[clap(long = "single-file", help = "Generate bindings as a single file.")]
#[serde(skip)]
single_file: bool,

#[clap(long = "skip-cargo-toml", help = "Skip Cargo.toml from consistency checks.")]
#[serde(skip)]
skip_cargo_toml: bool,
}

impl BindArgs {
Expand Down Expand Up @@ -109,6 +113,7 @@ No contract artifacts found. Hint: Have you built your contracts yet? `forge bin
&self.crate_version,
self.bindings_root(),
self.single_file,
!self.skip_cargo_toml,
)?;
} else {
bindings.ensure_consistent_module(self.bindings_root(), self.single_file)?;
Expand Down Expand Up @@ -141,7 +146,7 @@ impl Cmd for BindArgs {
fn run(self) -> eyre::Result<Self::Output> {
if !self.overwrite && self.bindings_exist() {
println!("Bindings found. Checking for consistency.");
return self.check_existing_bindings()
return self.check_existing_bindings();
}

if self.overwrite {
Expand Down

0 comments on commit 923d19e

Please sign in to comment.