Clean up formatting and remove redundant debug output in main.zig
This commit is contained in:
@@ -1,14 +1,12 @@
|
||||
const zocket = @import("zocket");
|
||||
|
||||
const std = @import("std");
|
||||
const std = @import("std");
|
||||
const builtin = @import("builtin");
|
||||
|
||||
pub fn main(init: std.process.Init) !void
|
||||
{
|
||||
const io = init.io;
|
||||
|
||||
std.debug.print("{any}\n", .{builtin.mode});
|
||||
|
||||
if (builtin.mode == .Debug)
|
||||
{
|
||||
var arena: std.heap.DebugAllocator(.{}) = .init;
|
||||
@@ -23,10 +21,10 @@ pub fn main(init: std.process.Init) !void
|
||||
|
||||
const allocator = arena.allocator();
|
||||
|
||||
var tmpArena = std.heap.ArenaAllocator.init(std.heap.smp_allocator);
|
||||
var tmpArena = std.heap.ArenaAllocator.init(std.heap.smp_allocator);
|
||||
const tmpAllocator = tmpArena.allocator();
|
||||
|
||||
const exe = try std.process.executableDirPathAlloc(io, tmpAllocator);
|
||||
const exe = try std.process.executableDirPathAlloc(io, tmpAllocator);
|
||||
const path = try std.fs.path.join(allocator, &.{ exe, "zocket/config.toml" });
|
||||
|
||||
tmpArena.deinit();
|
||||
|
||||
Reference in New Issue
Block a user