diff options
author | 2022-01-03 22:17:34 -0800 | |
---|---|---|
committer | 2022-01-03 22:17:34 -0800 | |
commit | 0960f3d6d1b6460e1a7a4dcec4921d2cf664df72 (patch) | |
tree | 6928d162d1c2a9fac43fd7fdbc6c9cebb8cfa63c /src/cli.zig | |
parent | 64b49ddd951e4e94978497302cd73e8ce8114010 (diff) | |
download | bun-0960f3d6d1b6460e1a7a4dcec4921d2cf664df72.tar.gz bun-0960f3d6d1b6460e1a7a4dcec4921d2cf664df72.tar.zst bun-0960f3d6d1b6460e1a7a4dcec4921d2cf664df72.zip |
Implement a crash reporter and improve some error handling in `bun install`
Diffstat (limited to 'src/cli.zig')
-rw-r--r-- | src/cli.zig | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/cli.zig b/src/cli.zig index fe03de014..b17dc8396 100644 --- a/src/cli.zig +++ b/src/cli.zig @@ -76,6 +76,8 @@ pub const Cli = struct { } }; } + + pub var cmd: ?Command.Tag = null; }; const LoaderMatcher = strings.ExactSizeMatcher(4); @@ -583,6 +585,8 @@ pub const Command = struct { debug: DebugOptions = DebugOptions{}, pub fn create(allocator: std.mem.Allocator, log: *logger.Log, comptime command: Command.Tag) anyerror!Context { + Cli.cmd = command; + var ctx = Command.Context{ .args = std.mem.zeroes(Api.TransformOptions), .log = log, |