const std = @import("std"); pub fn build(b: *std.Build) void { const target = b.standardTargetOptions(.{}); const optimize = b.standardOptimizeOption(.{}); const exe = b.addExecutable(.{ .name = "pick", .root_module = b.createModule(.{ .root_source_file = b.path("pick.zig"), .target = target, .optimize = optimize }) }); b.installArtifact(exe); const run_cmd = b.addRunArtifact(exe); run_cmd.step.dependOn(b.getInstallStep()); if (b.args) |args| run_cmd.addArgs(args); b.step("run", "Run pick").dependOn(&run_cmd.step); const smoke = b.addSystemCommand(&.{ "sh", "smoke.sh", "zig-out/bin/pick" }); smoke.setCwd(b.path(".")); smoke.step.dependOn(b.getInstallStep()); b.step("test", "Run smoke test").dependOn(&smoke.step); }