Skip to content

Commit

Permalink
docs: update tutorial with -E flag for env vars
Browse files Browse the repository at this point in the history
Signed-off-by: Alessio Greggi <[email protected]>
  • Loading branch information
alegrey91 committed Jan 10, 2025
1 parent bc9a36c commit 15a946a
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions docs/tutorials.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,18 @@ To do so, you have the `--dump-interval/-i` flag available. This flag gives you
harpoon capture -f main.main --dump-interval 2 -- ./binary_name
```

## Tracing a program that requires environment variables to run

`harpoon` provides support to pass environment variables to the executed command.

This is really useful to trace the command changing its behaviour through env vars.

Here's how you can pass multiple env vars to the executed command:

```sh
harpoon capture -f main.main -E "VAR1=value1" -E "VAR2=value2" -- ./binary_name
```

## Tracing from unit-tests

`harpoon` has additional commands other than `capture`. The commands are `analyze` and `hunt`.
Expand Down

0 comments on commit 15a946a

Please sign in to comment.