diff options
author | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2025-08-16 10:15:19 +0200 |
---|---|---|
committer | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2025-08-16 10:15:19 +0200 |
commit | c48d374e1070c264325f40645eda7117bd774bed (patch) | |
tree | c2209aa777ebbfd2d0b2d9649550f0dea5c5698b /src/cmd.zig | |
parent | b740fff1edd8217c54657e4ee33c65b4fe830704 (diff) |
DIR: Add /? flag.
Diffstat (limited to 'src/cmd.zig')
-rw-r--r-- | src/cmd.zig | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/cmd.zig b/src/cmd.zig index 7723e6b..755e659 100644 --- a/src/cmd.zig +++ b/src/cmd.zig @@ -26,6 +26,7 @@ const Date = @import("cmd/date.zig").Date; const Time = @import("cmd/time.zig").Time; const Sort = @import("cmd/sort.zig").Sort; const Move = @import("cmd/move.zig").Move; +const Help = @import("cmd/help.zig").Help; const External = @import("cmd/external.zig").External; const RedirectCommand = @import("cmd/redirect.zig").RedirectCommand; const PipeCommand = @import("cmd/pipe.zig").PipeCommand; @@ -99,7 +100,7 @@ pub const BuiltinCommand = union(enum) { Dosshell, Edit, Fasthelp, - Help, + Help: Help, Join, Mem, Power, @@ -215,6 +216,11 @@ pub const Command = union(enum) { allocator.free(set.value); }, .Rem => |rem| allocator.free(rem.message), + .Help => |help| { + if (help.command) |cmd| { + allocator.free(cmd); + } + }, .Rename => |rename| { switch (rename.from) { .Path => |path| allocator.free(path), |