Skip to content

Commit

Permalink
docs: add --locked to cargo commands
Browse files Browse the repository at this point in the history
  • Loading branch information
amaanq committed Jan 8, 2025
1 parent 018aed7 commit 87f9e4d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
10 changes: 5 additions & 5 deletions DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ You need to have all the necessary [tree-sitter](https://github.com/tree-sitter)
in `kernel` for the analysis to work. The `build` process will take care of this for you:

```shell
cargo build --profile release-dev
cargo build --locked --profile release-dev
```
> [!TIP]
> The use of the `release-dev` cargo profile is highly recommended, as runtime analysis speed is effectively
Expand All @@ -15,13 +15,13 @@ cargo build --profile release-dev

```shell

cargo run --profile release-dev --bin datadog-static-analyzer -- --directory <SOURCE> --output result.json --format sarif --debug yes
cargo run --locked --profile release-dev --bin datadog-static-analyzer -- --directory <SOURCE> --output result.json --format sarif --debug yes
```

## Start a local server

```shell
cargo run --profile release-dev --bin datadog-static-analyzer-server -- --port <server-port> -a <server-address>
cargo run --locked --profile release-dev --bin datadog-static-analyzer-server -- --port <server-port> -a <server-address>
```

## Run tests
Expand All @@ -36,7 +36,7 @@ cargo test
## Test a ruleset

```shell
cargo run --bin datadog-static-analyzer-test-ruleset -- -r <ruleset-name>1
cargo run --locked --bin datadog-static-analyzer-test-ruleset -- -r <ruleset-name>1
```


Expand All @@ -52,7 +52,7 @@ cargo test -- --nocapture
First, start the server using

```shell
cargo run --profile release-dev --bin datadog-static-analyzer-server
cargo run --locked --profile release-dev --bin datadog-static-analyzer-server
```


Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ diff aware not enabled (error when receiving diff-aware data from Datadog with c
Export rulesets from the API into a file

```shell
cargo run --bin datadog-export-rulesets -- -r <ruleset> -o <file-to-export>
cargo run --locked --bin datadog-export-rulesets -- -r <ruleset> -o <file-to-export>
```

## More
Expand Down
2 changes: 1 addition & 1 deletion doc/owasp-benchmark.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ git clone https://github.com/DataDog/datadog-static-analyzer.git
Then, run it. At the top directory of the static analyzer, use

```
cargo run --release --bin datadog-static-analyzer -- --format sarif --output /path/to/BenchmarkJava/results/Benchmark_1.2-DatadogSast.sarif --directory /path/to/BenchmarkJava
cargo run --locked --release --bin datadog-static-analyzer -- --format sarif --output /path/to/BenchmarkJava/results/Benchmark_1.2-DatadogSast.sarif --directory /path/to/BenchmarkJava
```


Expand Down

0 comments on commit 87f9e4d

Please sign in to comment.