You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+11-8Lines changed: 11 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,31 +6,34 @@ A recorder of Ruby programs that produces [CodeTracer](https://github.com/metacr
6
6
> Currently it is in a very early phase: we're welcoming contribution and discussion!
7
7
8
8
9
-
### usage
9
+
### Usage
10
10
11
11
you can currently use it directly with
12
12
13
13
```bash
14
-
ruby trace.rb <path to ruby file>
15
-
# produces several trace json files in the current directory
16
-
# or in the folder of `$CODETRACER_DB_TRACE_PATH` if such an env var is defined
14
+
ruby trace.rb [--out-dir DIR] <path to ruby file>
15
+
# produces several trace json files in DIR,
16
+
# or in `$CODETRACER_RUBY_RECORDER_OUT_DIR` if DIR is not provided.
17
+
# Defaults to the current directory.
18
+
# Pass --help to list all options.
17
19
```
18
20
19
21
You can also invoke a lightweight CLI that loads the native tracer extension
20
22
directly:
21
23
22
24
```bash
23
-
ruby src/native_trace.rb <path to ruby file>
25
+
ruby src/native_trace.rb [--out-dir DIR] <path to ruby file>
26
+
# Uses DIR or `$CODETRACER_RUBY_RECORDER_OUT_DIR` to choose where traces are saved.
24
27
```
25
28
26
29
however you probably want to use it in combination with CodeTracer, which would be released soon.
27
30
28
-
### env variables
31
+
### ENV variables
29
32
30
33
* if you pass `CODETRACER_RUBY_TRACER_DEBUG=1`, you enables some additional debug-related logging
31
-
*`CODETRACER_DB_TRACE_PATH` can be used to override the path to `trace.json` (it's used internally by codetracer as well)
34
+
*`CODETRACER_RUBY_RECORDER_OUT_DIR` can be used to specify the directory for trace files
32
35
33
-
## future directions
36
+
## Future directions
34
37
35
38
The current Ruby support is a prototype. In the future, it may be expanded to function in a way to similar to the more complete implementations, e.g. [Noir](https://github.com/blocksense-network/noir/tree/blocksense/tooling/tracer).
0 commit comments