diff options
| author | 2025-05-07 15:11:59 +0200 | |
|---|---|---|
| committer | 2025-05-07 15:41:00 +0200 | |
| commit | cc5c6a5d71a317ed4b0ad776842d1d0655f72d0a (patch) | |
| tree | de6972e86893dad79e2d1eee88fc64d0dfdb4f06 /build.zig | |
| parent | doc: Don't autogenerate the README (diff) | |
| download | zig-clap-cc5c6a5d71a317ed4b0ad776842d1d0655f72d0a.tar.gz zig-clap-cc5c6a5d71a317ed4b0ad776842d1d0655f72d0a.tar.xz zig-clap-cc5c6a5d71a317ed4b0ad776842d1d0655f72d0a.zip | |
chore: Update setup-zig to v2
Diffstat (limited to 'build.zig')
| -rw-r--r-- | build.zig | 8 |
1 files changed, 4 insertions, 4 deletions
| @@ -1,15 +1,15 @@ | |||
| 1 | pub fn build(b: *std.Build) void { | 1 | pub fn build(b: *std.Build) void { |
| 2 | const clap_mod = b.addModule("clap", .{ .root_source_file = b.path("clap.zig") }); | ||
| 3 | |||
| 4 | const optimize = b.standardOptimizeOption(.{}); | 2 | const optimize = b.standardOptimizeOption(.{}); |
| 5 | const target = b.standardTargetOptions(.{}); | 3 | const target = b.standardTargetOptions(.{}); |
| 6 | 4 | ||
| 7 | const test_step = b.step("test", "Run all tests in all modes."); | 5 | const clap_mod = b.addModule("clap", .{ |
| 8 | const tests = b.addTest(.{ | ||
| 9 | .root_source_file = b.path("clap.zig"), | 6 | .root_source_file = b.path("clap.zig"), |
| 10 | .target = target, | 7 | .target = target, |
| 11 | .optimize = optimize, | 8 | .optimize = optimize, |
| 12 | }); | 9 | }); |
| 10 | |||
| 11 | const test_step = b.step("test", "Run all tests in all modes."); | ||
| 12 | const tests = b.addTest(.{ .root_module = clap_mod }); | ||
| 13 | const run_tests = b.addRunArtifact(tests); | 13 | const run_tests = b.addRunArtifact(tests); |
| 14 | test_step.dependOn(&run_tests.step); | 14 | test_step.dependOn(&run_tests.step); |
| 15 | 15 | ||