Skip to content

Commit

Permalink
Merge pull request #28 from CoinFabrik/develop
Browse files Browse the repository at this point in the history
Merge develop into prod
  • Loading branch information
tenuki authored Apr 23, 2024
2 parents 5066110 + f7050a2 commit cd833d5
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 322 deletions.
2 changes: 1 addition & 1 deletion apps/cargo-scout-audit/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 2 additions & 6 deletions apps/cargo-scout-audit/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "cargo-scout-audit"
version = "0.2.7"
version = "0.2.9"
edition = "2021"
authors = [
"Agustin Aon <[email protected]>",
Expand All @@ -16,6 +16,7 @@ description = "Scout is an extensible open-source tool intended to assist Ink! a
readme = "../../README.md"
keywords = ["auditor", "security", "ink", "soroban", "smart-contracts"]
categories = ["development-tools", "command-line-utilities"]
repository = "https://github.com/coinfabrik/scout-audit"

[lib]
path = "src/lib.rs"
Expand Down Expand Up @@ -47,8 +48,3 @@ tempfile = "3.8"
toml = { version = "0.8.0" }
tera = {version = "=1.19.1", features=["builtins"]}
webbrowser = "=0.8.12"
pulldown-cmark = "0.10.0"

[dev-dependencies]
colored = "2.0.0"

12 changes: 11 additions & 1 deletion apps/cargo-scout-audit/src/startup.rs
Original file line number Diff line number Diff line change
Expand Up @@ -133,13 +133,23 @@ pub struct ProjectInfo {
pub workspace_root: PathBuf,
}

pub fn run_scout(opts: Scout) -> Result<()> {
pub fn run_scout(mut opts: Scout) -> Result<()> {
let opt_child = run_scout_in_nightly()?;
if let Some(mut child) = opt_child {
child.wait()?;
return Ok(());
}

// If the target is not set to wasm32-unknown-unknown, set it
let target_args_flag = "--target=wasm32-unknown-unknown".to_string();
let no_default = "--no-default-features".to_string();
let z_build_std = "-Zbuild-std=std,core,alloc".to_string();

if !opts.args.iter().any(|x| x.contains("--target=")) {
opts.args
.extend([target_args_flag, no_default, z_build_std])
}

// Validations
if opts.filter.is_some() && opts.exclude.is_some() {
panic!("You can't use `--exclude` and `--filter` at the same time.");
Expand Down
39 changes: 0 additions & 39 deletions apps/cargo-scout-audit/tests/README.md

This file was deleted.

149 changes: 0 additions & 149 deletions apps/cargo-scout-audit/tests/integration_tests/detectors.rs

This file was deleted.

This file was deleted.

14 changes: 0 additions & 14 deletions apps/cargo-scout-audit/tests/integration_tests/detectors/utils.rs

This file was deleted.

1 change: 0 additions & 1 deletion apps/cargo-scout-audit/tests/integration_tests/main.rs

This file was deleted.

0 comments on commit cd833d5

Please sign in to comment.