## Debugging with zig

02-12-2023

we build and test with `zig build test --summary all --color on`

![](./Media/Pasted%20image%2020231205153234.png)


This generates a folder named zig-cache with a bunch of shit in it
To find our test we can run `find zig-cache -name test`
You probably want to filter after the most recent
On ubuntu you probably also want the coredump so enable it with
`ulimit -c unlimited` and then run gdb as following

`gdb ./zig-cache/o/50e9f92e2e360a84e8b24a5eafb14156/test core`

![](./Media/Pasted%20image%2020231205142328.png)
