From e47dc4f7d8314e08952e15a0f66a84486014ddb7 Mon Sep 17 00:00:00 2001 From: murat Date: Mon, 25 May 2026 21:36:10 +0300 Subject: [PATCH] updated readme --- README.md | 64 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 63 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index e9fb885..6a53d41 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,64 @@ # fetchit -Works on my machine + +fetchit is a terminal-based system information viewer written in C++. It works like neofetch/fastfetch and consists of a single file (`main.cpp`). + +## Features + +- Displays distro, kernel, uptime, shell, CPU, GPU, RAM, and OS date information. +- Detects distro name via `/etc/os-release`. +- Shows ASCII logos for supported distros. +- Reads `/usr/share/hwdata/pci.ids` for GPU names; prints hex IDs if missing. +- Accounts for Unicode character width (for icon alignment). + +## Supported Distro Logos + +`arch`, `cachyos`, `debian`, `ubuntu`, `fedora`, `manjaro`, `opensuse`, `pop`, `linuxmint`, `endeavouros`, `void`, `alpine` + +## Requirements + +- Linux +- A C++17-capable compiler (e.g., g++) +- A UTF-8 terminal with ANSI color support (for icons and colors) +- The following files/paths are read: + - `/etc/os-release` + - `/etc/hostname` + - `/proc/uptime` + - `/proc/cpuinfo` + - `/proc/meminfo` + - `/sys/bus/pci/devices/` + - `/sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq` + - `/usr/share/hwdata/pci.ids` (optional) + +## Build + +```bash +g++ -std=c++17 -O2 -o fetchit main.cpp +``` + +## Run + +```bash +./fetchit +``` + +## Sample Output + +```text + --- murat@baklava --- + + /\  distro: Arch Linux + / \  kernel: 7.0.10-arch1-1 + / \  uptime: 1 minutes + / \  shell: /usr/bin/bash + / ,, \ 󰍛 CPU: 12th Gen Intel(R) Core(TM) i5-12500H (16) @ 4.5 GHz + / | | \ 󰾲 GPU: AD107M [GeForce RTX 4060 Max-Q / Mobile] / Alder Lake-P GT2 [Iris Xe Graphics] + /_-'' ''-_\  RAM: 15.2529 GB +  OS Date: 6 months 17 days 3 hours 40 minutes +``` + +## Notes + +- `OS Date` is based on the creation time of `/etc/hostname`. +- If no ASCII logo is found, only the info list is printed. +- The distro logo is displayed in color via ANSI escape codes. +- This tool targets Linux systems and is not expected to work on non-Linux OSes.