nxfetch 0.2.0

A minimal, fast and batteries included fetcher!
Documentation

A minimal, fast and batteries included fetcher!

nxfetch

image of nxfetch prompt

Installation

cargo install --git https://git.sr.ht/~sntx/nxfetch --locked
git clone https://git.sr.ht/~sntx/nxfetch && cd nxfetch
cargo install --path . --locked
nix shell sourcehut:~sntx/nxfetch

Usage

Usage: nxfetch [OPTIONS] [MODULES]...

Arguments:
  [MODULES]...  A list of module names nxfetch should display [possible values: title, user, host, os, kernel, uptime, shell, cpu, memory, colours, colours-bright, empty]

Options:
      --no-module-names
          Whether to hide the module names
  -l, --logo <LOGO>
          Path to text file with ascii art to use as the logo
      --no-logo
          Whether to hide the logo
      --padding-before <PADDING_BEFORE>
          Padding before the fetch [default: 2]
      --padding-between <PADDING_BETWEEN>
          Padding between the logo and the text [default: 2]
  -r, --raw
          Only print raw module output (same as `--no-logo --no-module-names --padding-before 0`, takes precedence over those args)
  -h, --help
          Print help
  -V, --version
          Print version

Performance

nxfetch 0.2.0 has been tested with hyperfine.

You can test nxfetch against other popular fetchers by running:

nix run .#benchmark
$ nix run .#benchmark
Benchmark 1: nxfetch
  Time (mean ± σ):       2.3 ms ±   0.3 ms    [User: 0.5 ms, System: 1.4 ms]
  Range (min … max):     1.7 ms …   3.5 ms    1104 runs
 
Benchmark 2: afetch
  Time (mean ± σ):       6.1 ms ±   0.4 ms    [User: 3.2 ms, System: 2.8 ms]
  Range (min … max):     5.1 ms …   8.9 ms    453 runs
 
Benchmark 3: bunnyfetch
  Time (mean ± σ):       5.1 ms ±   0.5 ms    [User: 1.7 ms, System: 3.4 ms]
  Range (min … max):     4.1 ms …   8.2 ms    470 runs
 
Benchmark 4: fastfetch
  Time (mean ± σ):      70.7 ms ±   4.4 ms    [User: 26.2 ms, System: 29.8 ms]
  Range (min … max):    65.3 ms …  89.1 ms    44 runs
 
Benchmark 5: inxi
  Time (mean ± σ):     747.0 ms ±   5.9 ms    [User: 251.1 ms, System: 132.2 ms]
  Range (min … max):   738.2 ms … 754.6 ms    10 runs
 
Benchmark 6: neofetch
  Time (mean ± σ):     966.4 ms ±  17.6 ms    [User: 319.0 ms, System: 250.9 ms]
  Range (min … max):   937.0 ms … 989.4 ms    10 runs
 
Benchmark 7: pfetch
  Time (mean ± σ):     203.5 ms ±   9.8 ms    [User: 93.7 ms, System: 48.0 ms]
  Range (min … max):   189.4 ms … 219.8 ms    14 runs
 
Benchmark 8: profetch
  Time (mean ± σ):       4.3 ms ±   0.4 ms    [User: 1.6 ms, System: 2.1 ms]
  Range (min … max):     3.4 ms …   6.5 ms    633 runs
 
Benchmark 9: yafetch
  Time (mean ± σ):     273.4 ms ±  17.8 ms    [User: 104.6 ms, System: 45.2 ms]
  Range (min … max):   256.2 ms … 301.0 ms    10 runs
 
Summary
  nxfetch ran
    1.86 ± 0.26 times faster than profetch
    2.18 ± 0.32 times faster than bunnyfetch
    2.62 ± 0.34 times faster than afetch
   30.21 ± 3.88 times faster than fastfetch
   86.91 ± 10.64 times faster than pfetch
  116.79 ± 15.17 times faster than yafetch
  319.07 ± 35.97 times faster than inxi
  412.80 ± 47.03 times faster than neofetch

Further Examples

nxfetch --no-logo

image of nxfetch prompt without ascii/ansi logo

nxfetch --raw uptime

12h1m40s

License

This repository is GPL-3.0-or-later licensed.