2019-09-24 09:33:23 +02:00
# pfetch
A pretty system information tool written in POSIX `sh` .
2019-09-24 12:07:10 +02:00
2019-09-26 20:28:41 +02:00
The goal of this project is to implement a simple system information tool in POSIX `sh` using features built into the language itself (*where possible*).
The source code is highly documented and I hope it will act as a learning resource for POSIX `sh` and simple information detection across various different operating systems.
If anything in the source code is unclear or is lacking in its explanation, open an issue. Sometimes you get too close to something and you fail to see the "bigger picture"!
2019-09-24 12:07:10 +02:00
```sh
➜ pfetch
___ goldie@KISS
(.· | os KISS Linux
(< > | host Lenovo YOGA 900-13ISK
/ __ \ kernel 5.3.1-coffee
( / \ /| uptime 6h 20m
_/\ __)/_) pkgs 130
2019-09-25 16:58:31 +02:00
\/-____\/ memory 1721M / 7942M
2019-09-24 12:07:10 +02:00
```
2019-09-24 12:43:18 +02:00
2019-09-24 20:08:33 +02:00
## OS support
2019-09-29 10:46:15 +02:00
- Linux
- Alpine Linux
- Arch Linux
- Arco Linux
- Artix Linux
- CentOS
- Debian
- Elementary
- Fedora
- Gentoo
- Guix
- Hyperbola
- KISS Linux
- Linux Lite
- Linux Mint
- Mageia
- Manjaro
- MX Linux
- NixOS
- OpenSUSE
- Parabola
- Pop!\_OS
- PureOS
- Slackware
2019-09-29 11:21:16 +02:00
- Ubuntu
2019-09-29 10:46:15 +02:00
- Void Linux
- BSD
- DragonflyBSD
- FreeBSD
- NetBSD
- OpenBSD
- MacOS
- Haiku
- Minix
2019-09-30 22:01:36 +02:00
- Solaris
2019-09-24 20:08:33 +02:00
2019-09-26 20:28:41 +02:00
## TODO
- [ ] Add optional and additional information detection.
- [ ] CPU
2019-09-27 20:04:00 +02:00
- [ ] Terminal Emulator ([#12](https://github.com/dylanaraps/pfetch/pull/12))
2019-09-26 20:28:41 +02:00
- The way I implement this in `neofetch` is interesting.
2019-09-27 21:03:34 +02:00
- [x] Terminal colors ([commit](https://github.com/dylanaraps/pfetch/commit/ba03cb3cf4dfbc767abce6acd53c07ab5568e23d))
2019-09-27 21:45:16 +02:00
- [ ] Window manager ([#13](https://github.com/dylanaraps/pfetch/pull/13))
2019-09-26 20:28:41 +02:00
- [ ] ???
- [ ] Expand operating system support.
2019-09-30 22:01:36 +02:00
- [x] Solaris ([#5](https://github.com/dylanaraps/pfetch/issues/5))
2019-09-28 14:04:05 +02:00
- [x] MINIX ([#6](https://github.com/dylanaraps/pfetch/issues/6))
2019-09-26 20:53:12 +02:00
- [ ] AIX ([#7](https://github.com/dylanaraps/pfetch/issues/7))
- [ ] IRIX ([#8](https://github.com/dylanaraps/pfetch/issues/8))
- [ ] FreeMiNT ([#9](https://github.com/dylanaraps/pfetch/issues/9))
- [ ] Windows ([#10](https://github.com/dylanaraps/pfetch/issues/10))
2019-09-26 20:28:41 +02:00
- [ ] CYGWIN
- [ ] MSYS
- [ ] MINGW
2019-09-28 09:32:41 +02:00
- [x] WSL (*this is fairly simple*)
2019-09-26 20:28:41 +02:00
2019-09-24 13:50:14 +02:00
## Configuration
`pfetch` is configured through environment variables.
```sh
# Which information to display.
# NOTE: If 'ascii' will be used, it must come first.
2019-09-24 15:15:35 +02:00
# Default: first example below
2019-09-24 13:50:14 +02:00
# Valid: space separated string
2019-09-24 21:52:13 +02:00
#
2019-09-27 20:49:44 +02:00
# OFF by default: shell palette
2019-09-29 16:25:26 +02:00
PF_INFO="ascii title os host kernel uptime pkgs memory"
2019-09-24 13:50:14 +02:00
# Example: Only ASCII.
PF_INFO="ascii"
# Example: Only Information.
2019-09-29 16:25:26 +02:00
PF_INFO="title os host kernel uptime pkgs memory"
2019-09-24 13:50:14 +02:00
# Separator between info name and info data.
2019-09-24 15:15:35 +02:00
# Default: unset
2019-09-24 13:50:14 +02:00
# Valid: string
PF_SEP=":"
# Color of info names:
2019-09-24 15:15:35 +02:00
# Default: unset (auto)
2019-09-24 13:50:14 +02:00
# Valid: 0-9
PF_COL1=4
# Color of info data:
2019-09-24 15:15:35 +02:00
# Default: unset (auto)
2019-09-24 13:50:14 +02:00
# Valid: 0-9
PF_COL2=7
2019-09-25 09:40:36 +02:00
# Color of title data:
# Default: unset (auto)
# Valid: 0-9
PF_COL3=1
2019-09-24 13:50:14 +02:00
# Alignment padding.
2019-09-24 15:15:35 +02:00
# Default: unset (auto)
2019-09-24 13:50:14 +02:00
# Valid: int
PF_ALIGN=""
2019-09-24 15:15:35 +02:00
# Which ascii art to use.
# Default: unset (auto)
# Valid: string
PF_ASCII="openbsd"
2019-09-24 13:50:14 +02:00
```
2019-09-24 20:52:25 +02:00
## Credit
- [ufetch ](https://gitlab.com/jschx/ufetch ): Lots of ASCII logos.
2019-09-27 08:10:04 +02:00
- Contrary to the belief of a certain youtuber, `pfetch` shares **zero** code with `ufetch` . Only some of the ASCII logos were used.