Skip to content

Commit cedfb30

Browse files
committed
cmd/init: fix for exe option
1 parent 4639401 commit cedfb30

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

src/cmd/init.zig

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,11 +193,15 @@ pub fn execute(self_name: []const u8, args: [][:0]u8) !void {
193193
\\ const mode = b.option(std.builtin.Mode, "mode", "") orelse .Debug;
194194
\\
195195
\\ const exe = b.addExecutable(.{
196+
\\
197+
);
198+
try w.print(" .name = \"{s}\",\n", .{name});
199+
try w.writeAll(
196200
\\ .root_source_file = b.path("main.zig"),
197201
\\ .target = target,
198202
\\ .optimize = mode,
199203
\\ });
200-
\\ deps.addAllTo(tests);
204+
\\ deps.addAllTo(exe);
201205
\\ b.installArtifact(exe);
202206
\\
203207
\\ const run_step = b.step("run", "Run the app");

0 commit comments

Comments
 (0)