Creates a top-level build step, exposed to the CLI user and advertised in the "--help" menu.
pub fn step(b: *Build, name: []const u8, description: []const u8) *Step
pub fn step(b: *Build, name: []const u8, description: []const u8) *Step {
const graph = b.graph;
const arena = graph.arena;
const step_info = arena.create(Step.TopLevel) catch @panic("OOM");
step_info.* = .{
.step = .init(.{
.tag = .top_level,
.name = name,
.owner = b,
}),
.description = graph.dupeString(description),
};
const gop = b.top_level_steps.getOrPut(arena, name) catch @panic("OOM");
if (gop.found_existing) panic("A top-level step with name \"{s}\" already exists", .{name});
gop.key_ptr.* = step_info.step.name;
gop.value_ptr.* = step_info;
return &step_info.step;
}