fakefetch

A fake fastfetch clone: prints device info that is fully CLI-controlled, unrelated to the actual machine.

fastfetch
moon add kokic/fakefetch@0.1.1
Download zip
Author
Version
0.1.1
License
AGPL-3.0
Last updated
6 hours ago
Downloads
5

Dependencies

README

#fakefetch

A fake fastfetch clone written in MoonBit. It prints device information in the same style as fastfetch, but every field is fake — nothing is read from the actual machine. All values come from built-in device profiles.

#Acknowledgments

All 22 logos are the original artwork shipped with fastfetch, including each logo's official multi-color palette.

#
Cpu

pub struct Cpu {
name : String
cores : Int
clock : Float
}

A CPU: vendor/model name, cores, and base clock in GHz.

#
Cpu::render

fn Cpu::render(self : Cpu) -> String

Format as fastfetch does, e.g. Apple M3 Max (16) @ 4.05 GHz.

#
DeviceModel

pub struct DeviceModel {
name : String
about : String
host : String
os : String
device : String
kernel : String
uptime : Uptime
shell : String
resolution : Resolution
de : String
wm : String
wm_theme : String
terminal : String
term_font : String
cpu : Cpu
gpu : Gpu
memory : Memory
logo : String
}

A coherent set of fake hardware/software values for one real device model. Every field is a plausible, internally-consistent value for that product.

#
Gpu

pub struct Gpu {
name : String
vram : Int
}

A GPU: vendor/model name and discrete VRAM in GB. vram is 0 when the GPU has no discrete memory (integrated/Apple silicon).

#
Gpu::render

fn Gpu::render(self : Gpu) -> String

Format as fastfetch does, e.g. NVIDIA GeForce RTX 4090 (24GB); a GPU without discrete VRAM renders as its bare name.

#
Memory

pub struct Memory {
used : Float
total : Float
}

A device's fake memory footprint: used and total, both in GiB. Only these two numbers are picked by the model; the display text (two-decimal GiB values and usage percentage) is derived from them.

#
Memory::render

fn Memory::render(self : Memory) -> String

Format as fastfetch does, e.g. 46.30 GiB / 128.00 GiB (36%).

#
Resolution

pub struct Resolution {
width : Int
height : Int
}

A display resolution: width and height in pixels.

#
Resolution::render

fn Resolution::render(self : Resolution) -> String

Format as fastfetch does, e.g. 3456x2234.

#
Uptime

pub struct Uptime {
hours : Int
mins : Int
}

System uptime in whole hours and mins.

#
Uptime::render

fn Uptime::render(self : Uptime) -> String

Format as fastfetch does, e.g. 3 hours, 12 mins.

#
all_gpus

fn all_gpus() -> Array[Gpu]

The built-in GPU catalog. Discrete GPUs carry a VRAM size in GB; integrated and Apple-silicon GPUs use 0 and render as their bare name.

#
all_models

fn all_models() -> Array[DeviceModel]

All available device profiles, in the order they are listed in help.

#
build_command

#
default_model

fn default_model() -> DeviceModel

The device profile used when --model is not given.

#
default_model_name

fn default_model_name() -> String

The name of the model used when --model is not given.

#
model_by_name

fn model_by_name(name : String) -> DeviceModel?

Look up a device profile by its --model name.

#
render

fn render(matches :
Matches
) -> String

Render the fake system-info output for the parsed command line.