diff options
| author | Juha Syrjälä <juha.syrjala@iki.fi> | 2020-09-29 20:56:30 +0300 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2020-10-16 21:29:24 -0400 |
| commit | 79ef96b6a4af3fff751d5d7ad679634643c4fc6e (patch) | |
| tree | 37c1fc837ce9b526254b732dc8d77d8c4444bdb7 /lib/std/special | |
| parent | 8a2d12d7075fe5eb68e12ccb2b662981b71ae677 (diff) | |
| download | zig-79ef96b6a4af3fff751d5d7ad679634643c4fc6e.tar.gz zig-79ef96b6a4af3fff751d5d7ad679634643c4fc6e.zip | |
Add support for `zig build run -- arg1 arg1` in file created by init-exe
Diffstat (limited to 'lib/std/special')
| -rw-r--r-- | lib/std/special/init-exe/build.zig | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/std/special/init-exe/build.zig b/lib/std/special/init-exe/build.zig index fd71588c5f..3a66254b02 100644 --- a/lib/std/special/init-exe/build.zig +++ b/lib/std/special/init-exe/build.zig @@ -18,6 +18,9 @@ pub fn build(b: *Builder) void { const run_cmd = exe.run(); run_cmd.step.dependOn(b.getInstallStep()); + if (b.args) |args| { + run_cmd.addArgs(args); + } const run_step = b.step("run", "Run the app"); run_step.dependOn(&run_cmd.step); |
