summaryrefslogtreecommitdiff
path: root/src/main.zig
diff options
context:
space:
mode:
authorsamposa_1337 <lososhome1@gmail.com>2026-11-12 15:06:58 +0300
committersamposa_1337 <lososhome1@gmail.com>2026-11-12 15:06:58 +0300
commitb2b5b31df357b82fc15e3ac5fae8c6506499e6ee (patch)
tree46a187e9f0f6be0700743c21c4aafbc6024f1f9e /src/main.zig
parent90e7ac5b453272e59a4f7403549990d7aae6cf55 (diff)
add de/wm
Diffstat (limited to 'src/main.zig')
-rw-r--r--src/main.zig48
1 files changed, 25 insertions, 23 deletions
diff --git a/src/main.zig b/src/main.zig
index fb35199..99bcdcd 100644
--- a/src/main.zig
+++ b/src/main.zig
@@ -4,28 +4,30 @@ const st = @import("stat.zig");
const artd = @import("art.zig");
pub fn main(init: std.process.Init) !void {
const allocator = init.arena.allocator();
- const ke = try st.getkernel(init.io ,allocator);
- const cpu = try st.getcpu(init.io ,allocator);
- const osg = try st.getos(init.io ,allocator);
- const ram = try st.getram(init.io ,allocator);
- const ramq = try st.gettotal(init.io ,allocator);
- const uptime = try st.uptime(init.io ,allocator);
- const user = try st.getuser(init.environ_map ,allocator);
- const shell = try st.getshell(init.environ_map ,allocator);
+ const ke = try st.getkernel(init.io, allocator);
+ const cpu = try st.getcpu(init.io, allocator);
+ const osg = try st.getos(init.io, allocator);
+ const ram = try st.getram(init.io, allocator);
+ const ramq = try st.gettotal(init.io, allocator);
+ const uptime = try st.uptime(init.io, allocator);
+ const user = try st.getuser(init.environ_map, allocator);
+ const shell = try st.getshell(init.environ_map, allocator);
+ const wm = try st.getwm(init.environ_map, allocator);
- const hostname = try st.gethostname(init.io ,allocator);
- var bufs: [1024]u8 = undefined;
- var stdw = Io.File.stdout().writer(init.io, &bufs);
- const stdout = &stdw.interface;
- const art = artd.logo;
- try stdout.print(" Ezfetch\n", .{});
- try stdout.print("{s} -----------------\n", .{art[0]});
- try stdout.print("{s} Os: {s}\n", .{art[1],osg});
- try stdout.print("{s} Username@hostname: {s}@{s}\n", .{art[2],user,hostname});
- try stdout.print("{s} Kernel: {s}\n", .{art[3],ke});
- try stdout.print("{s} Cpu: {s}\n", .{art[4],cpu});
- try stdout.print("{s} Ram: {s} / {s} \n", .{art[5],ramq,ram});
- try stdout.print(" larptime: {s}\n", .{uptime});
- try stdout.print(" shell: {s}\n", .{shell});
- try stdout.flush();
+ const hostname = try st.gethostname(init.io, allocator);
+ var bufs: [1024]u8 = undefined;
+ var stdw = Io.File.stdout().writer(init.io, &bufs);
+ const stdout = &stdw.interface;
+ const art = artd.logo;
+ try stdout.print(" Ezfetch\n", .{});
+ try stdout.print(" -----------------\n", .{});
+ try stdout.print("{s} Os: {s}\n", .{ art[0], osg });
+ try stdout.print("{s} Username@hostname: {s}@{s}\n", .{ art[1], user, hostname });
+ try stdout.print("{s} Kernel: {s}\n", .{ art[2], ke });
+ try stdout.print("{s} Cpu: {s}\n", .{ art[3], cpu });
+ try stdout.print("{s} Ram: {s} / {s} \n", .{ art[4], ramq, ram });
+ try stdout.print("{s} DE/WM: {s}\n", .{ art[5], wm });
+ try stdout.print(" larptime: {s}\n", .{uptime});
+ try stdout.print(" shell: {s}\n", .{shell});
+ try stdout.flush();
}