macOS port of nzuum/fetchit. All credit for the original design and implementation goes to nzuum and contributors; this fork adds a macOS backend.
A minimal system info fetcher written in C and configurable in lua
git clone https://codeberg.org/nzuum/fetchit && cd fetchit
sudo make install
make install-configfetchit will copy the init.lua and logos/logo.txt into your
~/.config/fetchit folder on install
column_padding = 2
art = {
source = "./logos/logo.txt"
}
function fetch()
return {
columns = {
art.out,
{
color.red(user.name .. "@" .. host.name),
color.red("os: ") .. string.lower(os.name),
color.yellow("kernel: ") .. kernel.sysname .. kernel.release,
color.green("cpu: ") .. string.lower(cpu.name),
color.blue("gpu: ") .. string.lower(gpu.name),
color.magenta("ram: ") .. string.format("%.1fGB/%.1fGB (%.1f%%)", memory.used_gb, memory.total_gb, memory.percent),
}
}
}
endthe default config only uses a few of the modules that fetchit exposes to the lua state. for a full list, look below
host.nameuser.nameos.namekernel.sysname
kernel.releasecpu.namegpu.name-- it is recommended to format x_gb. i.e: string.format(%.1fgb, memory.total_gb)
memory.total_gb
memory.used_gb
memory.available_gb
memory.percent-- it is recommended to format x_gb. i.e: string.format(%.1fgb, disk.total_gb)
disk.total_gb
disk.used_gbvendor.name
vendor.modeluptime.pretty -- 12h 6m
uptime.seconds -- 43560shell.nameterminal.nameart source is to be specified in the config file. the path is relative to the config's location
art = {
source = "path/to/file"
}color.black()
color.red()
color.green()
color.yellow()
color.blue()
color.magenta()
color.cyan()
color.white()
color.bright_black()
color.bright_red()
color.bright_green()
color.bright_yellow()
color.bright_blue()
color.bright_magenta()
color.bright_cyan()
color.bright_white()
color.bold()
color.reset()