We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c3562c3 commit 79e70eeCopy full SHA for 79e70ee
starter_templates/zig/build.zig
@@ -24,4 +24,10 @@ pub fn build(b: *std.Build) void {
24
// This will evaluate the `run` step rather than the default, which is "install".
25
const run_step = b.step("run", "Run the app");
26
run_step.dependOn(&run_cmd.step);
27
+
28
+ // This allows the user to pass arguments to the application in the build
29
+ // command itself, like this: `zig build run -- arg1 arg2 etc`
30
+ if (b.args) |args| {
31
+ run_cmd.addArgs(args);
32
+ }
33
}
0 commit comments