Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e28a3b96e5 | ||
|
|
01ad39c0b5 | ||
|
|
a18fd7ade8 | ||
|
|
3e14691e14 |
@@ -18,7 +18,7 @@ Zigfetch is a minimal [neofetch](https://github.com/dylanaraps/neofetch)/[fastfe
|
|||||||
|
|
||||||
### Linux only
|
### Linux only
|
||||||
|
|
||||||
- [libpci](https://github.com/pciutils/pciutils) (linux only)
|
- [libpci](https://github.com/pciutils/pciutils)
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
|
|
||||||
// This is a [Semantic Version](https://semver.org/).
|
// This is a [Semantic Version](https://semver.org/).
|
||||||
// In a future version of Zig it will be used for package deduplication.
|
// In a future version of Zig it will be used for package deduplication.
|
||||||
.version = "0.6.0",
|
.version = "0.6.1",
|
||||||
|
|
||||||
// Together with name, this represents a globally unique package
|
// Together with name, this represents a globally unique package
|
||||||
// identifier. This field is generated by the Zig toolchain when the
|
// identifier. This field is generated by the Zig toolchain when the
|
||||||
|
|||||||
@@ -105,11 +105,13 @@ pub fn printAscii(allocator: std.mem.Allocator, sys_info_list: std.ArrayList([]u
|
|||||||
if (i < sys_info_len) {
|
if (i < sys_info_len) {
|
||||||
try stdout.print("{s}\n", .{sys_info_items[i]});
|
try stdout.print("{s}\n", .{sys_info_items[i]});
|
||||||
} else if (i == sys_info_len + 1) {
|
} else if (i == sys_info_len + 1) {
|
||||||
|
// Print the first row of colors
|
||||||
for (0..8) |j| {
|
for (0..8) |j| {
|
||||||
try stdout.print("\x1b[48;5;{d}m \x1b[0m", .{j});
|
try stdout.print("\x1b[48;5;{d}m \x1b[0m", .{j});
|
||||||
}
|
}
|
||||||
try stdout.print("\n", .{});
|
try stdout.print("\n", .{});
|
||||||
} else if (i == sys_info_len + 2) {
|
} else if (i == sys_info_len + 2) {
|
||||||
|
// Print the second row of colors
|
||||||
for (8..16) |j| {
|
for (8..16) |j| {
|
||||||
try stdout.print("\x1b[48;5;{d}m \x1b[0m", .{j});
|
try stdout.print("\x1b[48;5;{d}m \x1b[0m", .{j});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,9 +23,9 @@ pub const ModuleType = enum {
|
|||||||
ram,
|
ram,
|
||||||
swap,
|
swap,
|
||||||
disk,
|
disk,
|
||||||
|
net,
|
||||||
terminal,
|
terminal,
|
||||||
locale,
|
locale,
|
||||||
net, // It must always be the last element of this array
|
|
||||||
};
|
};
|
||||||
|
|
||||||
pub fn getModulesTypes(allocator: std.mem.Allocator, config: ?std.json.Parsed(Config)) !std.ArrayList(ModuleType) {
|
pub fn getModulesTypes(allocator: std.mem.Allocator, config: ?std.json.Parsed(Config)) !std.ArrayList(ModuleType) {
|
||||||
|
|||||||
Reference in New Issue
Block a user