authorgravatar for 124872+jedisct1@users.noreply.github.comFrank Denis <124872+jedisct1@users.noreply.github.com> 2025-09-18 23:03:53+02:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2025-09-19 12:12:49+02:00
log7d8a9545785b3540ebd8e87d8039fc8239f660ab
treebdea2ffd5c52a84bfb605dc09e09cdbeeea9d199
parent91eab35e08f72220fd2461bdf6da2f74aaff5c64
signaturebadge-check Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

zig fmt help: mention that the argument can be a directory

I’ve been typing `zig fmt **/.zig` for a long time, until I discovered that the argument can actually be a directory. Mention this feature explicitly in the help message.

1 files changed, 1 insertions(+), 1 deletions(-)

src/fmt.zig+1-1
......@@ -156,7 +156,7 @@ pub fn run(gpa: Allocator, arena: Allocator, args: []const []const u8) !void {
156156 }
157157
158158 if (input_files.items.len == 0) {
159 fatal("expected at least one source file argument", .{});
159 fatal("expected at least one file or directory argument", .{});
160160 }
161161
162162 var stdout_buffer: [4096]u8 = undefined;