Files
nandi ca918a4a34
Copilot Setup Steps / copilot-setup-steps (push) Successful in 21s
feat: implement moonfetch (fastfetch clone in MoonBit native)
2026-11-17 22:19:58 +00:00

1.2 KiB

moonfetch

A fastfetch clone written in MoonBit targeting the native backend (native).

Features

  • ASCII Art Logos: Auto-detected from /etc/os-release (moonbit, debian, ubuntu, arch, fedora, alpine, linux) or selectable via --logo <name> / --no-logo.
  • System Info Modules:
    • user@hostname + separator
    • OS (PRETTY_NAME + arch)
    • Host / Model (/sys/devices/virtual/dmi/id/* or container/VM detection)
    • Kernel (uname)
    • Uptime (/proc/uptime)
    • Packages (dpkg, apk, pacman)
    • Shell & Terminal ($SHELL, $TERM_PROGRAM/$TERM, TIOCGWINSZ)
    • DE / WM ($XDG_CURRENT_DESKTOP, $WAYLAND_DISPLAY, $DISPLAY)
    • CPU (/proc/cpuinfo)
    • Memory (/proc/meminfo)
    • Disk (/) (statvfs)
    • Local IP (getifaddrs) & Locale ($LC_ALL/$LANG)
    • ANSI 16-color palette bar
  • CLI Options:
    • -h, --help
    • -v, --version
    • -l, --logo <name> / --no-logo
    • --no-color
    • --json
    • -s, --structure <modules> (colon- or comma-separated)
    • -c, --config <path>

Build & Test

moon check --target native
moon test --target native
moon build --target native --release
./_build/native/release/build/cmd/main/main.exe