This commit is contained in:
ekatwikz 2022-11-29 12:55:49 +01:00
commit aebc68b76a
346 changed files with 13350 additions and 492 deletions

2
.gitattributes vendored Normal file
View file

@ -0,0 +1,2 @@
# Auto detect text files and perform LF normalization
* text=auto

68
.github/workflows/arch_package.yml vendored Normal file
View file

@ -0,0 +1,68 @@
name: arch_package
on:
release:
types: [created]
jobs:
build:
runs-on: ubuntu-latest
container:
image: archlinux
options: --privileged
volumes:
- /sys/fs/cgroup:/sys/fs/cgroup
steps:
- name: Prepare environment
run: |
pacman -Syu --needed --noconfirm base-devel git openssh
sed -i '/E_ROOT/d' /usr/bin/makepkg
- name: Import AUR key
run: |
mkdir ~/.ssh && chmod 700 ~/.ssh
echo '${{secrets.AUR_SSH_PRIVATE_KEY}}' >> ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
ssh-keyscan -H aur.archlinux.org >> /etc/ssh/ssh_known_hosts
- name: Clone from AUR
run: |
export GIT_SSH_COMMAND='ssh -i ~/.ssh/id_rsa'
git clone ssh://aur@aur.archlinux.org/hyfetch.git
- name: Upgrade PKGBUILD
run: |
cd hyfetch
sed -i "/^pkgver=/cpkgver=${{github.ref_name}}" PKGBUILD
sed -i "/^pkgrel=/cpkgrel=1" PKGBUILD
- name: Makepkg
run: |
cd hyfetch
yes | makepkg -si
- name: Test hyfetch
run: |
hyfetch --test-print
- name: Upload binaries to release
uses: shogo82148/actions-upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: hyfetch/hyfetch*.pkg.tar.*
- name: set git info
run: |
git config --global user.name "Aleksana BOT"
git config --global user.email "me@aleksana.moe"
- name: Update PKGBUILD to AUR
run: |
cd hyfetch
rm -r .SRCINFO && makepkg --printsrcinfo >.SRCINFO
git stage . && git commit -m "BOT: upgrade to ${{github.ref_name}}"
export GIT_SSH_COMMAND='ssh -i ~/.ssh/id_rsa'
git push

115
.github/workflows/release.yml vendored Normal file
View file

@ -0,0 +1,115 @@
name: release
on:
push:
branches:
- "release/*"
jobs:
testing:
name: testing release
runs-on: ubuntu-latest
if: ${{ !startsWith(github.event.head_commit.message,'release') }}
steps:
- name: Checkout repo
uses: actions/checkout@v3
- name: Get tags
run: git fetch --all --tags
- name: Get version
run: |
BRANCH=$(git symbolic-ref --short HEAD)
VER=${BRANCH#*release/}
if [[ $(git tag | grep ${VER}rc) ]];then
TAGS=$(git tag | grep ${VER}rc | awk 'END {print}')
REL=${TAGS##*rc}
let REL++
else
REL=1
fi
echo "BUILDVER=${VER}rc${REL}" >> $GITHUB_ENV
- name: Update versions
run: |
sed -i "/^ *VERSION = /cVERSION = '${{ env.BUILDVER }}'" hyfetch/constants.py
- name: Making tags
run: |
git config user.name github-actions
git config user.email github-actions@github.com
git stage .
git commit -m "tagged unstable ${{ env.BUILDVER }}"
git tag --force ${{ env.BUILDVER }}
- name: Upload changes
run: |
git pull && git push && git push --tags
- name: Deploy to PYPI
uses: casperdcl/deploy-pypi@v2
with:
password: ${{ secrets.PYPI_API_TOKEN }}
pip: wheel -w dist/ --no-deps .
release:
name: formal release
runs-on: ubuntu-latest
if: ${{ startsWith(github.event.head_commit.message,'release') }}
steps:
- name: Checkout repo
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Get version
run: |
BRANCH=$(git symbolic-ref --short HEAD)
echo "BUILDVER=${BRANCH#*release/}" >> $GITHUB_ENV
- name: Update package.json
uses: jossef/action-set-json-field@v2
with:
file: package.json
field: version
value: ${{ env.BUILDVER }}
- name: Update neofetch version
run: |
REVISION=$(expr $(git rev-list --count HEAD neofetch) - 2902)
sed -i "/^ *version=/cversion=7.4.0r${REVISION}" neofetch
- name: Update other versions
run: |
sed -i "/^ *VERSION = /cVERSION = '${{ env.BUILDVER }}'" hyfetch/constants.py
sed -i "/^ *### Unpublished/c### ${{ env.BUILDVER }}" README.md
- name: Make final tags
run: |
git config user.name github-actions
git config user.email github-actions@github.com
git stage . && git commit -m "tagged stable ${{ env.BUILDVER }}"
git tag --force ${{ env.BUILDVER }}
- name: Merge branch and push
run: |
parent=$(git show-branch \
| grep -F '*' \
| grep -v "$(git rev-parse --abbrev-ref HEAD)" \
| head -n1 \
| sed 's/.*\[\(.*\)\].*/\1/' \
| sed 's/[\^~].*//')
git checkout ${parent}
git merge release/${{ env.BUILDVER }} --allow-unrelated-histories
git pull --all && git push --all && git push --tags
- name: Generate changelog from README
run: (sed '0,/^ *### ${{ env.BUILDVER }}/d;/^ *#/,$d' <README.md)>temp_CHANGELOG.md
- name: Publish release
uses: ncipollo/release-action@v1
with:
bodyFile: "temp_CHANGELOG.md"
tag: ${{ env.BUILDVER }}
token: ${{ secrets.GH_TOKEN }}

24
.github/workflows/shellcheck.yml vendored Normal file
View file

@ -0,0 +1,24 @@
name: Shellcheck
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
workflow_dispatch:
jobs:
# Shellcheck
check:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Install shellcheck
run: sudo apt-get update && sudo apt-get install -y shellcheck
- name: Run shellcheck
run: |
shellcheck -V
shellcheck neofetch
./neofetch

118
.gitignore vendored Normal file
View file

@ -0,0 +1,118 @@
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class
# C extensions
*.so
# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST
# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec
# Installer logs
pip-log.txt
pip-delete-this-directory.txt
# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
.hypothesis/
.pytest_cache/
# Translations
*.mo
*.pot
# Django stuff:
*.log
local_settings.py
db.sqlite3
# Flask stuff:
instance/
.webassets-cache
# Scrapy stuff:
.scrapy
# Sphinx documentation
docs/_build/
# PyBuilder
target/
# Jupyter Notebook
.ipynb_checkpoints
# IPython
profile_default/
ipython_config.py
# pyenv
.python-version
# celery beat schedule file
celerybeat-schedule
# SageMath parsed files
*.sage.py
# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/
# Spyder project settings
.spyderproject
.spyproject
# Rope project settings
.ropeproject
# mkdocs documentation
/site
# mypy
.mypy_cache/
.dmypy.json
dmypy.json
# Pyre type checker
.pyre/
# Custom
.idea
._*

1
MANIFEST.in Normal file
View file

@ -0,0 +1 @@
include hyfetch/scripts/*

412
README.md
View file

@ -1,3 +1,414 @@
# HyFetch
neofetch with pride flags <3
<img alt="screenshot" src="https://user-images.githubusercontent.com/22280294/197708447-ddee6db2-1017-48f2-b507-8ddf85acef0d.png">
### Running Updated Original Neofetch
This repo also serves as an updated version of the original `neofetch` since the upstream [dylanaraps/neofetch](https://github.com/dylanaraps/neofetch) doesn't seem to be maintained anymore (as of Jul 30, 2022, the original repo hasn't merged a pull request for 6 months). If you only want to use the updated neofetch without pride flags, you can use the `neofetch` script from this repo. To prevent command name conflict, I call it `neowofetch` :)
* Method 1: `pip install hyfetch` then run `neowofetch`
* Method 2: `npx neowofetch`
* Method 3: `P="$HOME/.local/bin/neowofetch" curl -L nf.hydev.org -o $P && chmod +x $P`
* Method 4: Run without install `bash <(curl -sL nf.hydev.org)`
## Installation
### Method 1: Install using Python pip (Recommended)
Install Python >= 3.7 first. Then, just do:
```sh
pip install hyfetch
```
### Method 2: Install using system package manager
Currently, these distributions have existing packages for HyFetch:
* Arch Linux: `paru -S hyfetch` or `yay -S hyfetch` (Thanks to [@Aleksana](https://github.com/Aleksanaa))
* Nix: `nix-env -i hyfetch` (Thanks to [@YisuiDenghua](https://github.com/YisuiDenghua))
* Guix: `guix install hyfetch` (Thanks to [@WammKD](https://github.com/WammKD))
### Method 3: Install the latest developmental version using git
Install Python >= 3.7 first. Then run the following commands:
```sh
git clone https://github.com/hykilpikonna/hyfetch.git
cd hyfetch
pip install .
```
## Usage
When you run `hyfetch` for the first time, it will prompt you to choose a color system and a preset. Just follow the prompt, and everything should work (hopefully). If something doesn't work, feel free to submit an issue!
If you want to use the updated `neofetch` without LGBTQ flags, check out [this section](https://github.com/hykilpikonna/hyfetch#running-updated-original-neofetch)
## Questions and answers
#### Q: How do I change my config?
A: Use `hyfetch -c`
#### Q: What do I do if the color is too dark/light for my theme?
A: You can try setting the colors' "lightness" in the configuration menu. The value should be between 0 and 1. For example, if you are using dark theme and the rainbow flag is too dark to display, you can set lightness to 0.7.
Feel free to experiment with it!
![image](https://user-images.githubusercontent.com/22280294/162614553-eb758e4e-1936-472c-8ca7-b601c696c6eb.png)
## Contributing
To make changes to our codebase, you first need to create a fork by clicking the "Fork" button on the top right. Then, you can clone your fork of the source code using `git clone https://github.com/{your username}/hyfetch.git`.
After making changes to the source code, you can run `python -m hyfetch` in the root directory of your repo to test out your changes.
If they work correctly, you can commit and push these changes using git command or Github Desktop. Then, you can create a pull request on Github so that it can go into our next release!
You can also install your version locally by running `pip install .` in the repo root.
## Change Log
### About Notation
Updates to HyFetch begins with the emoji 🌈
Updates to `neowofetch` begins with the emoji 🖼️
### TODO
* [ ] (Important!) Refactor flag storage & coloring to support non-stride patterns
* [ ] Config menu: Allow left-right arrow keys for pagination
* [ ] Neofetch argument pass through
<!-- CHANGELOG STARTS HERE --->
### Unpublished 1.4.5
Note: You can install the latest nightly version by using:
```sh
pip install git+https://github.com/hykilpikonna/hyfetch.git@master
```
* 🖼 Packages - Add tea.xyz package manager (issue [dylanaraps#2235](https://github.com/dylanaraps/neofetch/pull/2235))
### 1.4.4
* 🌈 Fix Python 3.11 compatibility (#35)
* 🌈 Fix many overflow problems when screen is too small
* 🖼️ Distro - Add Enso ([dylanaraps#2233](https://github.com/dylanaraps/neofetch/pull/2233))
* 🖼️ Memory - Optimize and fix memory unit conversion ([dylanaraps#2225](https://github.com/dylanaraps/neofetch/pull/2225))
* 🖼️ DE - Add dwl window manager ([dylanaraps#2234](https://github.com/dylanaraps/neofetch/pull/2234))
* 🖼️ DE - Fix XDG session detection for X11 ([dylanaraps#2232](https://github.com/dylanaraps/neofetch/pull/2232))
* 🖼️ CPU - Fix model detection for loongson (#34)
### 1.4.3
* 🌈 **Auto detect terminal background color & rgb support**
* 🌈 **Optimize experience on light-themed terminals**
* 🌈 Fix bugs with lightness and light-mode config not applying
* 🌈 Fix color alignment for distros with first color ≠ `${c1}` (e.g. Ubuntu Budgie)
* 🌈 Add unlabeled flags (#25)
* 🌈 Add gender nonconforming & femboy & tomboy flags (#32)
* 🌈 Fix jailbreak iOS shell `killed: 9` issue caused by ld signature check.
* 🖼️ Distro - Add garuda_small ([dylanaraps#2215](https://github.com/dylanaraps/neofetch/pull/2215))
* 🖼️ Distro - Add Cobalt Linux ([dylanaraps#2213](https://github.com/dylanaraps/neofetch/pull/2213))
* 🖼️ Distro - Add VanillaOS ([dylanaraps#2222](https://github.com/dylanaraps/neofetch/pull/2222))
* 🖼️ Distro - Surround macOS build number in parentheses (#28)
* 🖼️ Misc - Auto select stdout mode based on tty detection (#31)
* 🖼️ Bug Fix - Fix cols coloring reset for bash 3.2 (#24)
### 1.4.2
* 🌈 Detailed runnning/contributing instructions in README.md (#21)
* 🖼️ Distro - Add Stock Linux (#23)
* 🖼️ Distro - Add DietPi ([dylanaraps#1706](https://github.com/dylanaraps/neofetch/pull/1706))
* 🖼️ Distro - Add OmniOS illumos ([dylanaraps#2196](https://github.com/dylanaraps/neofetch/pull/2196))
* 🖼️ Distro - Add Droidian ([dylanaraps#2201](https://github.com/dylanaraps/neofetch/pull/2201))
* 🖼️ Distro - Add HamoniKR ([dylanaraps#2210](https://github.com/dylanaraps/neofetch/pull/2210))
* 🖼️ Song - Add support for TIDAL HiFi (#22)
* 🖼️ CPU - Detect multiple CPU models for ARM
* 🖼️ Misc - Better defaults: Show RAM in GiB, RAM percentage, CPU speed rounding, refresh rate
* 🖼️ Bug Fix - Fix bash 5.2 column cut off issue (#24)
### 1.4.1
* 🌈 Paginate flags (#14)
* 🌈 Add release workflow (#15)
* 🌈 Create automatic release script
* 🌈 Config page - Give warning when terminal size is too small
* 🌈 Config page - Optimize color arrangement selection on small screens
* 🌈 Add experimental Windows support (very unstable at the moment)
* 🖼️ Distro - Add ravynOS ([dylanaraps#2182](https://github.com/dylanaraps/neofetch/pull/2182))
* 🖼️ Distro - Add ChonkySealOS ([dylanaraps#2180](https://github.com/dylanaraps/neofetch/pull/2180))
* 🖼️ Distro - Add GhostBSD ([TheSudoer#18](https://github.com/hykilpikonna/hyfetch/pull/18))
* 🖼️ Distro - Add NekOS ([dylanaraps#2186](https://github.com/dylanaraps/neofetch/pull/2186))
* 🖼️ Distro - Add astOS ([dylanaraps#2185](https://github.com/dylanaraps/neofetch/pull/2185))
* 🖼️ Distro - Fix ChromeOS identification ([dylanaraps#1949](https://github.com/dylanaraps/neofetch/pull/1949))
* 🖼️ WM - Add Hyprland to the list of wayland wms ([dylanaraps#2190](https://github.com/dylanaraps/neofetch/pull/2190))
* 🖼️ Env - Add Java, Python, Node version detection (can be enabled in config)
* 🖼️ Bug Fix - Fix hostname detection when `inetutils` is not installed
* 🖼️ Bug Fix - Fix empty brackets displayed when no theme is found ([dylanaraps#1713](https://github.com/dylanaraps/neofetch/pull/1713))
* 🖼️ Bug Fix - Fix `$` escape bug in `strip_escape_codes()` ([dylanaraps#1543](https://github.com/dylanaraps/neofetch/pull/1543))
* 🖼️ Bug Fix - Fix backslash escape bug in `strip_escape_codes()` ([dylanaraps#1543](https://github.com/dylanaraps/neofetch/pull/1543))
* 🖼️ Bug Fix - Fix CPU detection on ARM QEMU
### 1.4.0
* 🌈 Add finsexual flag (#12)
* 🚀 Addressed a total of 128 currently open pull requests from neofetch
<details>
<summary>🖼️ Meta Changes</summary>
* Meta - Fixed shellcheck warnings in `neowofetch`
* Meta - Moved shellcheck from travis to GitHub Actions
* Meta - Created a script to automatically generate distro list
* Colors - Allow RGB colors in neofetch `--ascii_colors` argument ([dylanaraps#1726](https://github.com/dylanaraps/neofetch/pull/1726))
</details>
<details>
<summary>🖼️ Distro/OS Support Changes</summary>
* Distro - Update Ubuntu logo ([dylanaraps#2125](https://github.com/dylanaraps/neofetch/pull/2125))
* Distro - Add Exodia OS Predator ([dylanaraps#2174](https://github.com/dylanaraps/neofetch/pull/2174))
* Distro - Add Parch ([dylanaraps#2045](https://github.com/dylanaraps/neofetch/pull/2045))
* Distro - Add VzLinux ([dylanaraps#1971](https://github.com/dylanaraps/neofetch/pull/1971))
* Distro - Add Twister OS ([dylanaraps#1890](https://github.com/dylanaraps/neofetch/pull/1890))
* Distro - Add BlackPantherOS ([dylanaraps#1761](https://github.com/dylanaraps/neofetch/pull/1761))
* Distro - Add TorizonCore ([dylanaraps#1744](https://github.com/dylanaraps/neofetch/pull/1744))
* Distro - Add KrassOS ([dylanaraps#1631](https://github.com/dylanaraps/neofetch/pull/1631))
* Distro - Add Synology DSM ([dylanaraps#1666](https://github.com/dylanaraps/neofetch/pull/1666))
* Distro - Add MatuusOS ([dylanaraps#1902](https://github.com/dylanaraps/neofetch/pull/1902))
* Distro - Add HarDClanZ Linux ([dylanaraps#1797](https://github.com/dylanaraps/neofetch/pull/1797))
</details>
<details>
<summary>🖼️ Device Support Changes</summary>
* Host - Identify iMac, Mac mini, Mac Pro Models ([dylanaraps#1944](https://github.com/dylanaraps/neofetch/pull/1944))
* Host - Identify FreeBSD host model ([dylanaraps#1588](https://github.com/dylanaraps/neofetch/pull/1588))
* Font - Better font matching for st ([dylanaraps#1877](https://github.com/dylanaraps/neofetch/pull/1877))
* Theme - Use XSETTINGS to get theme without a DE ([dylanaraps#1831](https://github.com/dylanaraps/neofetch/pull/1831))
* Theme - Add QT theme detection ([dylanaraps#1713](https://github.com/dylanaraps/neofetch/pull/1713))
* Theme - Add LeftWM theme detection ([dylanaraps#1963](https://github.com/dylanaraps/neofetch/pull/1963))
* Cursor - Add cursor theme detection ([dylanaraps#1149](https://github.com/dylanaraps/neofetch/pull/1149))
* Terminal - Improve NixOS terminal identification ([dylanaraps#1134](https://github.com/dylanaraps/neofetch/pull/1134))
* Terminal - Use `/proc/.../cmdline` instead of `.../comm` ([dylanaraps#2034](https://github.com/dylanaraps/neofetch/pull/2034))
* Packages - Improve scoop/choco package count ([dylanaraps#1642](https://github.com/dylanaraps/neofetch/pull/1642))
</details>
<details>
<summary>🖼️ Bug Fixes</summary>
* Bug Fix - Fix prepended `=` for kitty ([dylanaraps#2116](https://github.com/dylanaraps/neofetch/pull/2116))
* Bug Fix - Hide domain in hostname by default ([dylanaraps#2095](https://github.com/dylanaraps/neofetch/pull/2095))
* Bug Fix - Respect TMPDIR if it exists ([dylanaraps#1891](https://github.com/dylanaraps/neofetch/pull/1891))
* Bug Fix - Fix terminal size over slow connection ([dylanaraps#1895](https://github.com/dylanaraps/neofetch/pull/1895))
* Bug Fix - Fix GPU detection for bumblebee dual-GPU ([dylanaraps#1131](https://github.com/dylanaraps/neofetch/pull/1131))
* Bug Fix - Strip colors in ASCII length calculation ([dylanaraps#1543](https://github.com/dylanaraps/neofetch/pull/1543))
</details>
### 1.3.0
<details>
<summary>🖼️ Ascii Art Changes</summary>
* Ascii - Improve Trisquel ([dylanaraps#1946](https://github.com/dylanaraps/neofetch/pull/1946))
* Ascii - Improve LangitKetujuh ([dylanaraps#1948](https://github.com/dylanaraps/neofetch/pull/1948))
* Ascii - Improve Artix small ([dylanaraps#1872](https://github.com/dylanaraps/neofetch/pull/1872))
* Ascii - Update Archcraft ([dylanaraps#1919](https://github.com/dylanaraps/neofetch/pull/1919))
</details>
<details>
<summary>🖼️ Distro/OS Support Changes</summary>
* OS - Support Old macOS 10.4 and 10.5 ([dylanaraps#2151](https://github.com/dylanaraps/neofetch/pull/2151))
* OS - Identify Hackintosh VM ([dylanaraps#2005](https://github.com/dylanaraps/neofetch/pull/2005))
* Distro - Fix model detection for Ubuntu Touch ([dylanaraps#2167](https://github.com/dylanaraps/neofetch/pull/2167))
* Distro - Add EncryptOS ([dylanaraps#2158](https://github.com/dylanaraps/neofetch/pull/2158))
* Distro - Add BigLinux ([dylanaraps#2061](https://github.com/dylanaraps/neofetch/pull/2061))
* Distro - Add AmogOS ([dylanaraps#1904](https://github.com/dylanaraps/neofetch/pull/1904))
* Distro - Add CutefishOS ([dylanaraps#2054](https://github.com/dylanaraps/neofetch/pull/2054))
* Distro - Add PearOS ([dylanaraps#2049](https://github.com/dylanaraps/neofetch/pull/2049))
* Distro - Add FusionX ([dylanaraps#2011](https://github.com/dylanaraps/neofetch/pull/2011))
* Distro - Add Q4OS ([dylanaraps#1973](https://github.com/dylanaraps/neofetch/pull/1973))
* Distro - Add CachyOS ([dylanaraps#2026](https://github.com/dylanaraps/neofetch/pull/2026))
* Distro - Add Soda Linux ([dylanaraps#2023](https://github.com/dylanaraps/neofetch/pull/2023))
* Distro - Add Elive Linux ([dylanaraps#1957](https://github.com/dylanaraps/neofetch/pull/1957))
* Distro - Add Uos ([dylanaraps#1991](https://github.com/dylanaraps/neofetch/pull/1991))
* Distro - Add MassOS ([dylanaraps#1947](https://github.com/dylanaraps/neofetch/pull/1947))
* Distro - Add CalinixOS ([dylanaraps#1988](https://github.com/dylanaraps/neofetch/pull/1988))
* Distro - Add Kaisen Linux ([dylanaraps#1958](https://github.com/dylanaraps/neofetch/pull/1958))
* Distro - Add yiffOS ([dylanaraps#1920](https://github.com/dylanaraps/neofetch/pull/1920))
* Distro - Add Sulin ([dylanaraps#1896](https://github.com/dylanaraps/neofetch/pull/1896))
* Distro - Add Wii Linux ([dylanaraps#1929](https://github.com/dylanaraps/neofetch/pull/1929))
* Distro - Add Linspire ([dylanaraps#1905](https://github.com/dylanaraps/neofetch/pull/1905))
* Distro - Add Ubuntu Kylin ([dylanaraps#1974](https://github.com/dylanaraps/neofetch/pull/1974))
* Distro - Add OPNsense ([dylanaraps#1055](https://github.com/dylanaraps/neofetch/pull/1055))
* Distro - Improve BSD machine arch detection ([dylanaraps#2015](https://github.com/dylanaraps/neofetch/pull/2015))
* Distro - Improve Manjaro version detection ([dylanaraps#1879](https://github.com/dylanaraps/neofetch/pull/1879))
</details>
<details>
<summary>🖼️ Device Support Changes</summary>
* Terminal - Add Fig ([dylanaraps#2077](https://github.com/dylanaraps/neofetch/pull/2077))
* Terminal - Identify font for Apple Terminal ([dylanaraps#2017](https://github.com/dylanaraps/neofetch/pull/2017))
* CPU - Identify core count for Apple M1 ([dylanaraps#2038](https://github.com/dylanaraps/neofetch/pull/2038))
* GPU - Identify OpenCL GPU without PCIe ([dylanaraps#1928](https://github.com/dylanaraps/neofetch/pull/1928))
* Host - Identify MacBook & Update iDevice models ([dylanaraps#1944](https://github.com/dylanaraps/neofetch/pull/1944))
* Battery - Identify power adapter for MacBooks ([dylanaraps#1945](https://github.com/dylanaraps/neofetch/pull/1945))
* DE - Identify KF5 and Qt versions for Plasma ([dylanaraps#2019](https://github.com/dylanaraps/neofetch/pull/2019))
* Packages - Improve GUIX package detection ([dylanaraps#2021](https://github.com/dylanaraps/neofetch/pull/2021))
* Packages - Add `pm` and `cargo` ([dylanaraps#1876](https://github.com/dylanaraps/neofetch/pull/1876))
* Network - Identify network capabilities ([dylanaraps#1511](https://github.com/dylanaraps/neofetch/pull/1511))
</details>
<details>
<summary>🖼️ Bug Fixes</summary>
* Bug Fix - Fix `col_offset` ([dylanaraps#2042](https://github.com/dylanaraps/neofetch/pull/2042))
* Bug Fix - Prioritize `/etc/os-release` ([dylanaraps#2067](https://github.com/dylanaraps/neofetch/pull/2067))
* Bug Fix - Ignore case when counting `.appimage` ([dylanaraps#2006](https://github.com/dylanaraps/neofetch/pull/2006))
* Bug Fix - Fix BSD freezing if pkg is not bootstrapped ([dylanaraps#2014](https://github.com/dylanaraps/neofetch/pull/2014))
* Bug Fix - Fix wrong icon theme ([dylanaraps#1873](https://github.com/dylanaraps/neofetch/pull/1873))
</details>
### 1.2.0
* 🚀 Take over `neofetch` with `neowofetch`
<details>
<summary>🖼️ Ascii Art Changes</summary>
* Ascii - Add uwuntu ([#9](https://github.com/hykilpikonna/hyfetch/pull/9)) (use it with `hyfetch --test-distro uwuntu` or `neowofetch --ascii_distro uwuntu`)
* Ascii - Better Void ascii art ([#10](https://github.com/hykilpikonna/hyfetch/pull/10))
* Ascii - Update old NixOS logo for compatibility ([dylanaraps#2114](https://github.com/dylanaraps/neofetch/pull/2114))
</details>
<details>
<summary>🖼️ Distro/OS Support Changes</summary>
* OS - Identify macOS 13 Ventura ([#8](https://github.com/hykilpikonna/hyfetch/pull/8))
* OS - Windows 11 Fluent ([dylanaraps#2109](https://github.com/dylanaraps/neofetch/pull/2109))
* Distro - Add Asahi Linux ([dylanaraps#2079](https://github.com/dylanaraps/neofetch/pull/2079))
* Distro - Add CenterOS ([dylanaraps#2097](https://github.com/dylanaraps/neofetch/pull/2097))
* Distro - Add Finnix ([dylanaraps#2099](https://github.com/dylanaraps/neofetch/pull/2099))
* Distro - Add Miracle Linux ([dylanaraps#2085](https://github.com/dylanaraps/neofetch/pull/2085))
* Distro - Add Univalent ([dylanaraps#2162](https://github.com/dylanaraps/neofetch/pull/2162))
* Distro - Add NomadBSD ([dylanaraps#2147](https://github.com/dylanaraps/neofetch/pull/2147))
* Distro - Add GrapheneOS ([dylanaraps#2146](https://github.com/dylanaraps/neofetch/pull/2146))
* Distro - Add ShastraOS ([dylanaraps#2149](https://github.com/dylanaraps/neofetch/pull/2149))
* Distro - Add Ubuntu Touch ([dylanaraps#2167](https://github.com/dylanaraps/neofetch/pull/2167))
* Distro - Add Ubuntu Sway ([dylanaraps#2136](https://github.com/dylanaraps/neofetch/pull/2136))
* Distro - Add Orchid Linux ([dylanaraps#2144](https://github.com/dylanaraps/neofetch/pull/2144))
* Distro - Add AOSC OS/Retro ([dylanaraps#2124](https://github.com/dylanaraps/neofetch/pull/2124))
* Distro - Add Ultramarine Linux ([dylanaraps#2115](https://github.com/dylanaraps/neofetch/pull/2115))
* Distro - Improve NixOS version detection ([dylanaraps#2157](https://github.com/dylanaraps/neofetch/pull/2157))
</details>
<details>
<summary>🖼️ Device/Program Support Changes</summary>
* Terminal - Add Termux ([dylanaraps#1923](https://github.com/dylanaraps/neofetch/pull/1923))
* CPU - Add loongarch64 ([dylanaraps#2140](https://github.com/dylanaraps/neofetch/pull/2140))
* CPU - Identify CPU name for ARM / RISCV ([dylanaraps#2139](https://github.com/dylanaraps/neofetch/pull/2139))
* Battery - Fix file not found ([dylanaraps#2130](https://github.com/dylanaraps/neofetch/pull/2130))
* GPU - Identify open-kernal Nvidia driver version ([dylanaraps#2128](https://github.com/dylanaraps/neofetch/pull/2128))
</details>
<details>
<summary>🖼️ Bug Fixes</summary>
* Bug Fix - Fix broken fedora output ([dylanaraps#2084](https://github.com/dylanaraps/neofetch/pull/2084))
</details>
<img width="200px" src="https://user-images.githubusercontent.com/22280294/181790059-47aa6f80-be99-4e67-8fa5-5c02b02842c6.png" align="right">
### 1.1.3rc1
* 🌈 Add foreground-background color arrangement to make Fedora and Ubuntu look nicer
* 🌈 Allow typing abbreviations in flag selection
* 🌈 Fix: Duplicate random color arrangements are appearing in selection screen
* 🌈 Fix: Inconsistant color arrangement when saved to config file
### 1.1.2
* Add more flags ([#5](https://github.com/hykilpikonna/hyfetch/pull/5))
* Removed `numpy` dependency that was used in 1.1.0
<img width="200px" src="https://user-images.githubusercontent.com/22280294/180901539-014f036e-c926-4470-ac72-a6d6dcf30672.png" align="right">
### 1.1.0
* Refactored a lot of things
* Added Beiyang flag xD
* Added interactive configurator for brightness adjustment
* Added dark/light mode selection
* Added color bar preview for RGB/8bit mode selection
* Added random color arrangement feature (for NixOS)
### 1.0.7
* Fix: Make config path not on init but when it's actually needed.
### 1.0.6
* Remove `hypy_utils` dependency to make packaging easier.
### 1.0.5
* Fix terminal emulator detection ([PR #2](https://github.com/hykilpikonna/hyfetch/pull/2))
### 1.0.4
* Add more flags ([PR #1](https://github.com/hykilpikonna/hyfetch/pull/1))
### 1.0.3
* Fix missing dependency for setuptools
### 1.0.2
* Implement RGB to 8bit conversion
* Add support for Python 3.7 and 3.8
### 1.0.1
* Included 11 flag presets
* Ability to lighten colors with `--c-set-l <lightness>`
* Command-line flag chooser
* Supports Python >= 3.9
## More Screenshots
![image](https://user-images.githubusercontent.com/22280294/162614578-3b878abb-2a32-4427-997e-f90b3f5cfd7c.png)
![image](https://user-images.githubusercontent.com/22280294/162661621-f1c61338-7857-4d3f-9fe3-c6b635d68c38.png)
## Original Readme from Neofetch Below
<h3 align="center"><img src="https://i.imgur.com/ZQI2EYz.png" alt="logo" height="100px"></h3>
<p align="center">A command-line system information tool written in bash 3.2+</p>
@ -19,6 +430,7 @@ The information by default is displayed alongside your operating system's logo.
You can further configure Neofetch to display exactly what you want it to. Through the use of command-line flags and the configuration file you can change existing information outputs or add your own custom ones.
Neofetch supports almost 150 different operating systems. From Linux to Windows, all the way to more obscure operating systems like Minix, AIX and Haiku. If your favourite operating system is unsupported: Open up an issue and support will be added.

36
default.nix Normal file
View file

@ -0,0 +1,36 @@
with import <nixpkgs> {};
rec {
hyfetch = python3Packages.buildPythonPackage rec {
pname = "HyFetch";
version = "1.0.7";
src = pythonPackages.fetchPypi {
inherit pname version;
hash = "sha256-3/6/3EtTqHXTMuRIo2nclIxYSzOFvQegR29OJsKMQU4=";
};
propagatedBuildInputs = with python3Packages; [
typing-extensions
setuptools
];
doCheck = false;
meta = with lib; {
description = "neofetch with pride flags <3";
longDescription = ''
HyFetch is a command-line system information tool fork of neofetch.
HyFetch displays information about your system next to your OS logo
in ASCII representation. The ASCII representation is then colored in
the pattern of the pride flag of your choice. The main purpose of
HyFetch is to be used in screenshots to show other users what
operating system or distribution you are running, what theme or
icon set you are using, etc.
'';
homepage = "https://github.com/hykilpikonna/HyFetch";
license = licenses.mit;
mainProgram = "hyfetch";
};
};
}

9
hyfetch/__init__.py Normal file
View file

@ -0,0 +1,9 @@
from __future__ import annotations
from . import main, constants
__version__ = constants.VERSION
if __name__ == '__main__':
main.run()

4
hyfetch/__main__.py Normal file
View file

@ -0,0 +1,4 @@
from hyfetch import main
if __name__ == '__main__':
main.run()

76
hyfetch/color_scale.py Normal file
View file

@ -0,0 +1,76 @@
"""
This version of color_scale is a special version made without numpy dependency. The numpy version
would be faster, but numpy is 11 MB large. In comparison, hyfetch 1.0.7 is only 105 kB, so it's not
a good idea to depend on numpy.
"""
from __future__ import annotations
from .color_util import RGB
def create_gradient_hex(colors: list[str], resolution: int = 300) -> list[RGB]:
"""
Create gradient array from hex
"""
colors = [RGB.from_hex(s) for s in colors]
return create_gradient(colors, resolution)
def create_gradient(colors: list[RGB], resolution: int) -> list[RGB]:
"""
Create gradient array
Usage: arr[ratio / len(arr)] = Scaled gradient color at that point
"""
result = []
# Create gradient mapping
for i in range(len(colors) - 1):
c1 = colors[i]
c2 = colors[i + 1]
bi = i * resolution
for ri in range(resolution):
ratio = ri / resolution
r = int(c2.r * ratio + c1.r * (1 - ratio))
g = int(c2.g * ratio + c1.g * (1 - ratio))
b = int(c2.b * ratio + c1.b * (1 - ratio))
result.append(RGB(r, g, b))
return result
def get_raw(gradient: list[RGB], ratio: float) -> RGB:
"""
:param gradient: Gradient array (2d)
:param ratio: Between 0-1
:return: RGB subarray (1d, has 3 values)
"""
if ratio == 1:
return gradient[-1]
i = int(ratio * len(gradient))
return gradient[i]
class Scale:
colors: list[RGB]
rgb: list[RGB]
def __init__(self, scale: list[str], resolution: int = 300):
self.colors = [RGB.from_hex(s) for s in scale]
self.rgb = create_gradient(self.colors, resolution)
def __call__(self, ratio: float) -> RGB:
"""
:param ratio: Between 0-1
"""
return get_raw(self.rgb, ratio)
def test_color_scale():
scale = Scale(['#232323', '#4F1879', '#B43A78', '#F98766', '#FCFAC0'])
colors = 100
for i in range(colors + 1):
print(scale(i / colors).to_ansi_rgb(False), end=' ')

223
hyfetch/color_util.py Normal file
View file

@ -0,0 +1,223 @@
from __future__ import annotations
import colorsys
from dataclasses import dataclass, astuple
from typing_extensions import Literal
from .constants import GLOBAL_CFG
AnsiMode = Literal['default', 'ansi', '8bit', 'rgb']
LightDark = Literal['light', 'dark']
MINECRAFT_COLORS = ["&0/\033[0;30m", "&1/\033[0;34m", "&2/\033[0;32m", "&3/\033[0;36m", "&4/\033[0;31m",
"&5/\033[0;35m", "&6/\033[0;33m", "&7/\033[0;37m", "&8/\033[1;30m", "&9/\033[1;34m",
"&a/\033[1;32m", "&b/\033[1;36m", "&c/\033[1;31m", "&d/\033[1;35m", "&e/\033[1;33m",
"&f/\033[1;37m",
"&r/\033[0m", "&l/\033[1m", "&o/\033[3m", "&n/\033[4m", "&-/\n"]
MINECRAFT_COLORS = [(r[:2], r[3:]) for r in MINECRAFT_COLORS]
def color(msg: str) -> str:
"""
Replace extended minecraft color codes in string
:param msg: Message with minecraft color codes
:return: Message with escape codes
"""
for code, esc in MINECRAFT_COLORS:
msg = msg.replace(code, esc)
while '&gf(' in msg or '&gb(' in msg:
i = msg.index('&gf(') if '&gf(' in msg else msg.index('&gb(')
end = msg.index(')', i)
code = msg[i + 4:end]
fore = msg[i + 2] == 'f'
if code.startswith('#'):
rgb = tuple(int(code.lstrip('#')[i:i+2], 16) for i in (0, 2, 4))
else:
code = code.replace(',', ' ').replace(';', ' ').replace(' ', ' ')
rgb = tuple(int(c) for c in code.split(' '))
msg = msg[:i] + RGB(*rgb).to_ansi(foreground=fore) + msg[end + 1:]
return msg
def printc(msg: str):
"""
Print with color
:param msg: Message with minecraft color codes
"""
print(color(msg + '&r'))
def clear_screen(title: str = ''):
"""
Clear screen using ANSI escape codes
"""
if not GLOBAL_CFG.debug:
print('\033[2J\033[H', end='')
if title:
print()
printc(title)
print()
def redistribute_rgb(r: int, g: int, b: int) -> tuple[int, int, int]:
"""
Redistribute RGB after lightening
Credit: https://stackoverflow.com/a/141943/7346633
"""
threshold = 255.999
m = max(r, g, b)
if m <= threshold:
return int(r), int(g), int(b)
total = r + g + b
if total >= 3 * threshold:
return int(threshold), int(threshold), int(threshold)
x = (3 * threshold - total) / (3 * m - total)
gray = threshold - x * m
return int(gray + x * r), int(gray + x * g), int(gray + x * b)
@dataclass(unsafe_hash=True)
class HSL:
h: float
s: float
l: float
def __iter__(self):
return iter(astuple(self))
def rgb(self) -> RGB:
return RGB(*[round(v * 255.0) for v in colorsys.hls_to_rgb(self.h, self.l, self.s)])
@dataclass(unsafe_hash=True)
class RGB:
r: int
g: int
b: int
def __iter__(self):
return iter(astuple(self))
@classmethod
def from_hex(cls, hex: str) -> "RGB":
"""
Create color from hex code
>>> RGB.from_hex('#FFAAB7')
RGB(r=255, g=170, b=183)
:param hex: Hex color code
:return: RGB object
"""
hex = hex.lstrip("#")
r = int(hex[0:2], 16)
g = int(hex[2:4], 16)
b = int(hex[4:6], 16)
return cls(r, g, b)
def to_ansi_rgb(self, foreground: bool = True) -> str:
"""
Convert RGB to ANSI TrueColor (RGB) Escape Code.
This uses the 24-bit color encoding (an uint8 for each color value), and supports 16 million
colors. However, not all terminal emulators support this escape code. (For example, IntelliJ
debug console doesn't support it).
Currently, we do not know how to detect whether a terminal environment supports ANSI RGB. If
you have any thoughts, feel free to submit an issue on our Github page!
:param foreground: Whether the color is for foreground text or background color
:return: ANSI RGB escape code like \033[38;2;255;100;0m
"""
c = '38' if foreground else '48'
return f'\033[{c};2;{self.r};{self.g};{self.b}m'
def to_ansi_8bit(self, foreground: bool = True) -> str:
"""
Convert RGB to ANSI 8bit 256 Color Escape Code.
This encoding supports 256 colors in total.
:return: ANSI 256 escape code like \033[38;5;206m'
"""
r, g, b = self.r, self.g, self.b
sep = 42.5
while True:
if r < sep or g < sep or b < sep:
gray = r < sep and g < sep and b < sep
break
sep += 42.5
if gray:
color = 232 + (r + g + b) / 33
else:
color = 16 + int(r / 256. * 6) * 36 + int(g / 256. * 6) * 6 + int(b / 256. * 6)
c = '38' if foreground else '48'
return f'\033[{c};5;{int(color)}m'
def to_ansi_16(self, foreground: bool = True) -> str:
"""
Convert RGB to ANSI 16 Color Escape Code
:return: ANSI 16 escape code
"""
raise NotImplementedError()
def to_ansi(self, mode: AnsiMode | None = None, foreground: bool = True):
if not mode:
mode = GLOBAL_CFG.color_mode
if mode == 'rgb':
return self.to_ansi_rgb(foreground)
if mode == '8bit':
return self.to_ansi_8bit(foreground)
if mode == 'ansi':
return self.to_ansi_16(foreground)
def lighten(self, multiplier: float) -> 'RGB':
"""
Lighten the color by a multiplier
:param multiplier: Multiplier
:return: Lightened color (original isn't modified)
"""
return RGB(*redistribute_rgb(*[v * multiplier for v in self]))
def hsl(self) -> HSL:
h, l, s = colorsys.rgb_to_hls(*[v / 255.0 for v in self])
return HSL(h, s, l)
def set_light(self, light: float, at_least: bool | None = None, at_most: bool | None = None) -> 'RGB':
"""
Set HSL lightness value
:param light: Lightness value (0-1)
:param at_least: Set the lightness to at least this value (no change if greater)
:param at_most: Set the lightness to at most this value (no change if lesser)
:return: New color (original isn't modified)
"""
# Convert to HSL
hsl = self.hsl()
# Modify light value
if at_least is None and at_most is None:
hsl.l = light
else:
if at_most:
hsl.l = min(hsl.l, light)
if at_least:
hsl.l = max(hsl.l, light)
# Convert back to RGB
return hsl.rgb()
def is_light(self):
return self.hsl().l > 0.5

50
hyfetch/constants.py Normal file
View file

@ -0,0 +1,50 @@
from __future__ import annotations
import os
from dataclasses import dataclass
from pathlib import Path
from typing_extensions import Literal
CONFIG_PATH = Path.home() / '.config/hyfetch.json'
VERSION = '1.4.4'
TEST_ASCII = r"""
### |\___/| ###
### ) ( ###
## =\ /= ##
#### )===( ####
### / \ ###
### | | ###
## / {txt} \ ##
## \ / ##
_/\_\_ _/_/\_
|##| ( ( |##|
|##| ) ) |##|
|##| (_( |##|""".strip('\n')
TEST_ASCII_WIDTH = max(len(line) for line in TEST_ASCII.split('\n'))
DEFAULT_DARK_L = 0.
@dataclass
class GlobalConfig:
# Global color mode default to 8-bit for compatibility
color_mode: str
override_distro: str | None
debug: bool
is_light: bool
def light_dark(self) -> Literal['light', 'dark']:
return 'light' if self.is_light else 'dark'
def default_lightness(self, term: Literal['light', 'dark'] | None = None) -> float:
if term is None:
term = self.light_dark()
return 0.65 if term.lower() == 'dark' else 0.4
GLOBAL_CFG = GlobalConfig(color_mode='8bit', override_distro=None, debug=False, is_light=False)
MINGIT_URL = 'https://github.com/git-for-windows/git/releases/download/v2.37.2.windows.2/MinGit-2.37.2.2-busybox-32-bit.zip'

25
hyfetch/distro.py Normal file
View file

@ -0,0 +1,25 @@
from __future__ import annotations
import string
asciis: list['AsciiArt'] = []
class AsciiArt:
name: str
match: str
color: str
ascii: str
def __init__(self, match: str, color: str, ascii: str, name: str | None = None):
self.match = match
self.color = color
self.ascii = ascii
self.name = name or self.get_friendly_name()
asciis.append(self)
def get_friendly_name(self) -> str:
return self.match.split("|")[0].strip(string.punctuation + '* ') \
.replace('"', '').replace('*', '')

422
hyfetch/main.py Executable file
View file

@ -0,0 +1,422 @@
#!/usr/bin/env python3
from __future__ import annotations
import argparse
import json
import random
import traceback
from itertools import permutations
from math import ceil
from typing import Iterable
from . import termenv
from .color_scale import Scale
from .color_util import printc, clear_screen
from .constants import *
from .models import Config
from .neofetch_util import *
from .presets import PRESETS
def check_config() -> Config:
"""
Check if the configuration exists. Return the config object if it exists. If not, call the
config creator
TODO: Config path param
:return: Config object
"""
if CONFIG_PATH.is_file():
try:
return Config.from_dict(json.loads(CONFIG_PATH.read_text('utf-8')))
except KeyError:
return create_config()
return create_config()
def literal_input(prompt: str, options: Iterable[str], default: str, show_ops: bool = True) -> str:
"""
Ask the user to provide an input among a list of options
:param prompt: Input prompt
:param options: Options
:param default: Default option
:param show_ops: Show options
:return: Selection
"""
options = list(options)
lows = [o.lower() for o in options]
if show_ops:
op_text = '|'.join([f'&l&n{o}&r' if o == default else o for o in options])
printc(f'{prompt} ({op_text})')
else:
printc(f'{prompt} (default: {default})')
def find_selection(sel: str):
if not sel:
return None
# Find exact match
if sel in lows:
return options[lows.index(sel)]
# Find starting abbreviation
for i, op in enumerate(lows):
if op.startswith(sel):
return options[i]
return None
selection = input('> ').lower() or default
while not find_selection(selection):
print(f'Invalid selection! {selection} is not one of {"|".join(options)}')
selection = input('> ').lower() or default
print()
return find_selection(selection)
def create_config() -> Config:
"""
Create config interactively
:return: Config object (automatically stored)
"""
# Detect terminal environment (doesn't work on Windows)
det_bg = termenv.get_background_color()
det_ansi = termenv.detect_ansi_mode()
asc = get_distro_ascii()
asc_width, asc_lines = ascii_size(asc)
logo = color("&b&lhyfetch&r" if det_bg is None or det_bg.is_light() else "&b&lhy&f&lfetch&r")
title = f'Welcome to {logo} Let\'s set up some colors first.'
clear_screen(title)
option_counter = 1
def update_title(k: str, v: str):
nonlocal title, option_counter
if not k.endswith(":"):
k += ':'
title += f"\n&e{option_counter}. {k.ljust(30)} &r{v}"
option_counter += 1
def print_title_prompt(prompt: str):
printc(f'&a{option_counter}. {prompt}')
##############################
# 0. Check term size
try:
term_len, term_lines = os.get_terminal_size().columns, os.get_terminal_size().lines
if term_len < 2 * asc_width + 4 or term_lines < 30:
printc(f'&cWarning: Your terminal is too small ({term_len} * {term_lines}). \n'
f'Please resize it for better experience.')
input('Press any key to ignore...')
except:
# print('Warning: We cannot detect your terminal size.')
pass
##############################
# 1. Select color system
def select_color_system():
if det_ansi == 'rgb':
return 'rgb', 'Detected color mode'
clear_screen(title)
term_len, term_lines = term_size()
scale2 = Scale(['#12c2e9', '#c471ed', '#f7797d'])
_8bit = [scale2(i / term_len).to_ansi_8bit(False) for i in range(term_len)]
_rgb = [scale2(i / term_len).to_ansi_rgb(False) for i in range(term_len)]
printc('&f' + ''.join(c + t for c, t in zip(_8bit, '8bit Color Testing'.center(term_len))))
printc('&f' + ''.join(c + t for c, t in zip(_rgb, 'RGB Color Testing'.center(term_len))))
print()
print_title_prompt('Which &bcolor system &ado you want to use?')
printc(f'(If you can\'t see colors under "RGB Color Testing", please choose 8bit)')
print()
return literal_input('Your choice?', ['8bit', 'rgb'], 'rgb'), 'Selected color mode'
# Override global color mode
color_system, ttl = select_color_system()
GLOBAL_CFG.color_mode = color_system
update_title(ttl, color_system)
##############################
# 2. Select light/dark mode
def select_light_dark():
if det_bg is not None:
return det_bg.is_light(), 'Detected background color'
clear_screen(title)
inp = literal_input(f'2. Is your terminal in &blight mode&r or &4dark mode&r?',
['light', 'dark'], 'dark')
return inp == 'light', 'Selected background color'
is_light, ttl = select_light_dark()
light_dark = 'light' if is_light else 'dark'
GLOBAL_CFG.is_light = is_light
update_title(ttl, light_dark)
##############################
# 3. Choose preset
# Create flags = [[lines]]
flags = []
spacing = max(max(len(k) for k in PRESETS.keys()), 20)
for name, preset in PRESETS.items():
flag = preset.color_text(' ' * spacing, foreground=False)
flags.append([name.center(spacing), flag, flag, flag])
# Calculate flags per row
flags_per_row = term_size()[0] // (spacing + 2)
row_per_page = max(1, (term_size()[1] - 13) // 5)
num_pages = ceil(len(flags) / (flags_per_row * row_per_page))
# Create pages
pages = []
for i in range(num_pages):
page = []
for j in range(row_per_page):
page.append(flags[:flags_per_row])
flags = flags[flags_per_row:]
if not flags:
break
pages.append(page)
def print_flag_page(page: list[list[list[str]]], page_num: int):
clear_screen(title)
print_title_prompt("Let's choose a flag!")
printc('Available flag presets:')
print(f'Page: {page_num + 1} of {num_pages}')
print()
for i in page:
print_flag_row(i)
print()
def print_flag_row(current: list[list[str]]):
[printc(' '.join(line)) for line in zip(*current)]
print()
page = 0
while True:
print_flag_page(pages[page], page)
tmp = PRESETS['rainbow'].set_light_dl_def(light_dark).color_text('preset')
opts = list(PRESETS.keys())
if page < num_pages - 1:
opts.append('next')
if page > 0:
opts.append('prev')
print("Enter 'next' to go to the next page and 'prev' to go to the previous page.")
preset = literal_input(f'Which {tmp} do you want to use? ', opts, 'rainbow', show_ops=False)
if preset == 'next':
page += 1
elif preset == 'prev':
page -= 1
else:
_prs = PRESETS[preset]
update_title('Selected flag', _prs.set_light_dl_def(light_dark).color_text(preset))
break
#############################
# 4. Dim/lighten colors
def select_lightness():
clear_screen(title)
print_title_prompt("Let's adjust the color brightness!")
printc(f'The colors might be a little bit too {"bright" if is_light else "dark"} for {light_dark} mode.')
print()
# Print cats
num_cols = (term_size()[0] // (TEST_ASCII_WIDTH + 2)) or 1
mn, mx = 0.15, 0.85
ratios = [col / num_cols for col in range(num_cols)]
ratios = [(r * (mx - mn) / 2 + mn) if is_light else ((r * (mx - mn) + (mx + mn)) / 2) for r in ratios]
lines = [ColorAlignment('horizontal').recolor_ascii(TEST_ASCII.replace(
'{txt}', f'{r * 100:.0f}%'.center(5)), _prs.set_light_dl(r, light_dark)).split('\n') for r in ratios]
[printc(' '.join(line)) for line in zip(*lines)]
def_lightness = GLOBAL_CFG.default_lightness(light_dark)
while True:
print()
printc(f'Which brightness level looks the best? (Default: {def_lightness * 100:.0f}% for {light_dark} mode)')
lightness = input('> ').strip().lower() or None
# Parse lightness
if not lightness or lightness in ['unset', 'none']:
return def_lightness
try:
lightness = int(lightness[:-1]) / 100 if lightness.endswith('%') else float(lightness)
assert 0 <= lightness <= 1
return lightness
except Exception:
printc('&cUnable to parse lightness value, please input it as a decimal or percentage (e.g. 0.5 or 50%)')
lightness = select_lightness()
_prs = _prs.set_light_dl(lightness, light_dark)
update_title('Selected Brightness', f"{lightness:.2f}")
#############################
# 5. Color arrangement
color_alignment = None
fore_back = get_fore_back()
# Calculate amount of row/column that can be displayed on screen
ascii_per_row = max(1, term_size()[0] // (asc_width + 2))
ascii_rows = max(1, (term_size()[1] - 8) // asc_lines)
# Displays horizontal and vertical arrangements in the first iteration, but hide them in
# later iterations
hv_arrangements = [
('Horizontal', ColorAlignment('horizontal', fore_back=fore_back)),
('Vertical', ColorAlignment('vertical'))
]
arrangements = hv_arrangements.copy()
# Loop for random rolling
while True:
clear_screen(title)
# Random color schemes
pis = list(range(len(_prs.unique_colors().colors)))
slots = list(set(re.findall('(?<=\\${c)[0-9](?=})', asc)))
while len(pis) < len(slots):
pis += pis
perm = {p[:len(slots)] for p in permutations(pis)}
random_count = max(0, ascii_per_row * ascii_rows - len(arrangements))
if random_count > len(perm):
choices = perm
else:
choices = random.sample(sorted(perm), random_count)
choices = [{slots[i]: n for i, n in enumerate(c)} for c in choices]
arrangements += [(f'random{i}', ColorAlignment('custom', r)) for i, r in enumerate(choices)]
asciis = [[*ca.recolor_ascii(asc, _prs).split('\n'), k.center(asc_width)] for k, ca in arrangements]
while asciis:
current = asciis[:ascii_per_row]
asciis = asciis[ascii_per_row:]
# Print by row
[printc(' '.join(line)) for line in zip(*current)]
print()
print_title_prompt("Let's choose a color arrangement!")
printc(f'You can choose standard horizontal or vertical alignment, or use one of the random color schemes.')
print('You can type "roll" to randomize again.')
print()
choice = literal_input(f'Your choice?', ['horizontal', 'vertical', 'roll'] + [f'random{i}' for i in range(random_count)], 'horizontal')
if choice == 'roll':
arrangements = []
continue
# Save choice
arrangement_index = {k.lower(): ca for k, ca in hv_arrangements + arrangements}
if choice in arrangement_index:
color_alignment = arrangement_index[choice]
else:
print('Invalid choice.')
continue
break
update_title('Color alignment', color_alignment)
# Create config
clear_screen(title)
c = Config(preset, color_system, light_dark, lightness, color_alignment)
# Save config
print()
save = literal_input(f'Save config?', ['y', 'n'], 'y')
if save == 'y':
c.save()
return c
def run():
# Optional: Import readline
try:
import readline
except ModuleNotFoundError:
pass
# Create CLI
hyfetch = color('&b&lhyfetch&r')
parser = argparse.ArgumentParser(description=color(f'{hyfetch} - neofetch with flags <3'))
parser.add_argument('-c', '--config', action='store_true', help=color(f'Configure {hyfetch}'))
parser.add_argument('-p', '--preset', help=f'Use preset', choices=PRESETS.keys())
parser.add_argument('-m', '--mode', help=f'Color mode', choices=['8bit', 'rgb'])
parser.add_argument('--c-scale', dest='scale', help=f'Lighten colors by a multiplier', type=float)
parser.add_argument('--c-set-l', dest='light', help=f'Set lightness value of the colors', type=float)
parser.add_argument('-V', '--version', dest='version', action='store_true', help=f'Check version')
parser.add_argument('--debug', action='store_true', help=f'Debug mode')
parser.add_argument('--test-distro', help=f'Test for a specific distro')
parser.add_argument('--test-print', action='store_true', help=f'Test print distro ascii art only')
parser.add_argument('--ask-exit', action='store_true', help=f'Ask before exitting')
args = parser.parse_args()
if args.version:
print(f'Version is {VERSION}')
return
# Ensure git bash for windows
ensure_git_bash()
check_windows_cmd()
# Test distro ascii art
if args.test_distro:
print(f'Setting distro to {args.test_distro}')
GLOBAL_CFG.override_distro = args.test_distro
if args.debug:
GLOBAL_CFG.debug = True
if args.test_print:
print(get_distro_ascii())
return
# Load config or create config
config = create_config() if args.config else check_config()
# Param overwrite config
if args.preset:
config.preset = args.preset
if args.mode:
config.mode = args.mode
# Override global color mode
GLOBAL_CFG.color_mode = config.mode
GLOBAL_CFG.is_light = config.light_dark == 'light'
# Get preset
preset = PRESETS.get(config.preset)
# Lighten (args > config)
if args.scale:
preset = preset.lighten(args.scale)
elif args.light:
preset = preset.set_light_raw(args.light)
else:
preset = preset.set_light_dl(config.lightness or GLOBAL_CFG.default_lightness())
# Run
try:
run_neofetch(preset, config.color_align)
except Exception as e:
print(f'Error: {e}')
traceback.print_exc()
if args.ask_exit:
input('Press any key to exit...')

26
hyfetch/models.py Normal file
View file

@ -0,0 +1,26 @@
from __future__ import annotations
from dataclasses import dataclass, field
from .color_util import AnsiMode, LightDark
from .constants import CONFIG_PATH
from .neofetch_util import ColorAlignment
from .serializer import json_stringify, from_dict
@dataclass
class Config:
preset: str
mode: AnsiMode
light_dark: LightDark = 'dark'
lightness: float | None = None
color_align: ColorAlignment = field(default_factory=lambda: ColorAlignment('horizontal'))
@classmethod
def from_dict(cls, d: dict):
d['color_align'] = ColorAlignment.from_dict(d['color_align'])
return from_dict(cls, d)
def save(self):
CONFIG_PATH.parent.mkdir(exist_ok=True, parents=True)
CONFIG_PATH.write_text(json_stringify(self), 'utf-8')

311
hyfetch/neofetch_util.py Normal file
View file

@ -0,0 +1,311 @@
from __future__ import annotations
import inspect
import os
import platform
import re
import shlex
import subprocess
import sys
import zipfile
from dataclasses import dataclass
from pathlib import Path
from subprocess import check_output
from tempfile import TemporaryDirectory
from urllib.request import urlretrieve
import pkg_resources
from typing_extensions import Literal
from hyfetch.color_util import color
from .constants import GLOBAL_CFG, MINGIT_URL
from .presets import ColorProfile
from .serializer import from_dict
RE_NEOFETCH_COLOR = re.compile('\\${c[0-9]}')
def term_size() -> tuple[int, int]:
"""
Get terminal size
:return:
"""
try:
return os.get_terminal_size().columns, os.get_terminal_size().lines
except Exception:
return 100, 20
def ascii_size(asc: str) -> tuple[int, int]:
"""
Get distro ascii width, height ignoring color code
:param asc: Distro ascii
:return: Width, Height
"""
return max(len(line) for line in re.sub(RE_NEOFETCH_COLOR, '', asc).split('\n')), len(asc.split('\n'))
def normalize_ascii(asc: str) -> str:
"""
Make sure every line are the same width
"""
w = ascii_size(asc)[0]
return '\n'.join(line + ' ' * (w - ascii_size(line)[0]) for line in asc.split('\n'))
def fill_starting(asc: str) -> str:
"""
Fill the missing starting placeholders.
E.g. "${c1}...\n..." -> "${c1}...\n${c1}..."
"""
new = []
last = ''
for line in asc.split('\n'):
new.append(last + line)
# Line has color placeholders
matches = RE_NEOFETCH_COLOR.findall(line)
if len(matches) > 0:
# Get the last placeholder for the next line
last = matches[-1]
return '\n'.join(new)
@dataclass
class ColorAlignment:
mode: Literal['horizontal', 'vertical', 'custom']
# custom_colors[ascii color index] = unique color index in preset
custom_colors: dict[int, int] = ()
# Foreground/background ascii color index
fore_back: tuple[int, int] = ()
@classmethod
def from_dict(cls, d: dict):
return from_dict(cls, d)
def recolor_ascii(self, asc: str, preset: ColorProfile) -> str:
"""
Use the color alignment to recolor an ascii art
:return Colored ascii, Uncolored lines
"""
asc = fill_starting(asc)
if self.fore_back and self.mode in ['horizontal', 'vertical']:
fore, back = self.fore_back
# Replace foreground colors
asc = asc.replace(f'${{c{fore}}}', color('&0' if GLOBAL_CFG.is_light else '&f'))
lines = asc.split('\n')
# Add new colors
if self.mode == 'horizontal':
colors = preset.with_length(len(lines))
asc = '\n'.join([l.replace(f'${{c{back}}}', colors[i].to_ansi()) + color('&r') for i, l in enumerate(lines)])
else:
raise NotImplementedError()
# Remove existing colors
asc = re.sub(RE_NEOFETCH_COLOR, '', asc)
elif self.mode in ['horizontal', 'vertical']:
# Remove existing colors
asc = re.sub(RE_NEOFETCH_COLOR, '', asc)
lines = asc.split('\n')
# Add new colors
if self.mode == 'horizontal':
colors = preset.with_length(len(lines))
asc = '\n'.join([colors[i].to_ansi() + l + color('&r') for i, l in enumerate(lines)])
else:
asc = '\n'.join(preset.color_text(line) + color('&r') for line in lines)
else:
preset = preset.unique_colors()
# Apply colors
color_map = {ai: preset.colors[pi].to_ansi() for ai, pi in self.custom_colors.items()}
for ascii_i, c in color_map.items():
asc = asc.replace(f'${{c{ascii_i}}}', c)
return asc
def get_command_path() -> str:
"""
Get the absolute path of the neofetch command
:return: Command path
"""
cmd_path = pkg_resources.resource_filename(__name__, 'scripts/neowofetch')
# Windows doesn't support symbolic links, but also I can't detect symbolic links... hard-code it here for now.
if platform.system() == 'Windows':
return str(Path(cmd_path).parent.parent.parent / 'neofetch')
return cmd_path
def ensure_git_bash() -> Path:
"""
Ensure git bash installation for windows
:returns git bash path
"""
if platform.system() == 'Windows':
# Find installation in default path
def_path = Path(r'C:\Program Files\Git\bin\bash.exe')
if def_path.is_file():
return def_path
# Find installation in PATH (C:\Program Files\Git\cmd should be in path)
pth = (os.environ.get('PATH') or '').lower().split(';')
pth = [p for p in pth if p.endswith(r'\git\cmd')]
if pth:
return Path(pth[0]).parent / r'bin\bash.exe'
# Previously downloaded portable installation
path = Path(__file__).parent / 'min_git'
pkg_path = path / 'package.zip'
if path.is_dir():
return path / r'bin\bash.exe'
# No installation found, download a portable installation
print('Git installation not found. Git is required to use HyFetch/neofetch on Windows')
print('Downloading a minimal portable package for Git...')
urlretrieve(MINGIT_URL, pkg_path)
print('Download finished! Extracting...')
with zipfile.ZipFile(pkg_path, 'r') as zip_ref:
zip_ref.extractall(path)
print('Done!')
return path / r'bin\bash.exe'
def check_windows_cmd():
"""
Check if this script is running under cmd.exe. If so, launch an external window with git bash
since cmd doesn't support RGB colors.
"""
if platform.system() == 'Windows':
import psutil
# TODO: This line does not correctly identify cmd prompts...
if psutil.Process(os.getppid()).name().lower().strip() == 'cmd.exe':
print("cmd.exe doesn't support RGB colors, restarting in MinTTY...")
cmd = f'"{ensure_git_bash().parent.parent / "usr/bin/mintty.exe"}" -s 110,40 -e python -m hyfetch --ask-exit'
os.system(cmd)
sys.exit(0)
def run_command(args: str, pipe: bool = False) -> str | None:
"""
Run neofetch command
"""
if platform.system() != 'Windows':
full_cmd = shlex.split(f'/usr/bin/env bash {get_command_path()} {args}')
else:
cmd = get_command_path().replace("\\", "/").replace("C:/", "/c/")
args = args.replace('\\', '/').replace('C:/', '/c/')
full_cmd = [ensure_git_bash(), '-c', f'{cmd} {args}']
# print(full_cmd)
if pipe:
return check_output(full_cmd).decode().strip()
else:
subprocess.run(full_cmd)
def get_distro_ascii(distro: str | None = None) -> str:
"""
Get the distro ascii of the current distro. Or if distro is specified, get the specific distro's
ascii art instead.
:return: Distro ascii
"""
if not distro and GLOBAL_CFG.override_distro:
distro = GLOBAL_CFG.override_distro
if GLOBAL_CFG.debug:
print(distro)
print(GLOBAL_CFG)
cmd = 'print_ascii'
if distro:
os.environ['CUSTOM_DISTRO'] = distro
cmd = 'print_custom_ascii'
asc = run_command(cmd, True)
# Unescape backslashes here because backslashes are escaped in neofetch for printf
asc = asc.replace('\\\\', '\\')
return normalize_ascii(asc)
def get_distro_name():
return run_command('ascii_distro_name', True)
def run_neofetch(preset: ColorProfile, alignment: ColorAlignment):
"""
Run neofetch with colors
:param preset: Color palette
:param alignment: Color alignment settings
"""
asc = get_distro_ascii()
w, h = ascii_size(asc)
asc = alignment.recolor_ascii(asc, preset)
# Escape backslashes here because backslashes are escaped in neofetch for printf
asc = asc.replace('\\', '\\\\')
# Write temp file
with TemporaryDirectory() as tmp_dir:
tmp_dir = Path(tmp_dir)
path = tmp_dir / 'ascii.txt'
path.write_text(asc)
# Call neofetch with the temp file
os.environ['ascii_len'] = str(w)
os.environ['ascii_lines'] = str(h)
run_command(f'--ascii --source {path.absolute()} --ascii-colors')
def get_fore_back(distro: str | None = None) -> tuple[int, int] | None:
"""
Get recommended foreground-background configuration for distro, or None if the distro ascii is
not suitable for fore-back configuration.
:return:
"""
if not distro and GLOBAL_CFG.override_distro:
distro = GLOBAL_CFG.override_distro
if not distro:
distro = get_distro_name().lower()
distro = distro.lower().replace(' ', '-')
for k, v in fore_back.items():
if distro == k.lower():
return v
return None
# Foreground-background recommendation
fore_back = {
'fedora': (2, 1),
'ubuntu': (2, 1),
'kubuntu': (2, 1),
'lubuntu': (2, 1),
'xubuntu': (2, 1),
'ubuntu-cinnamon': (2, 1),
'ubuntu-kylin': (2, 1),
'ubuntu-mate': (2, 1),
'ubuntu-studio': (2, 1),
'ubuntu-sway': (2, 1),
}

596
hyfetch/presets.py Normal file
View file

@ -0,0 +1,596 @@
from __future__ import annotations
from typing import Iterable
from typing_extensions import Literal
from .color_util import RGB, LightDark
from .constants import GLOBAL_CFG
def remove_duplicates(seq: Iterable) -> list:
"""
Remove duplicate items from a sequence while preserving the order
"""
seen = set()
seen_add = seen.add
return [x for x in seq if not (x in seen or seen_add(x))]
class ColorProfile:
raw: list[str]
colors: list[RGB]
spacing: Literal['equal', 'weighted'] = 'equal'
def __init__(self, colors: list[str] | list[RGB]):
if isinstance(colors[0], str):
self.raw = colors
self.colors = [RGB.from_hex(c) for c in colors]
else:
self.colors = colors
def with_weights(self, weights: list[int]) -> list[RGB]:
"""
Map colors based on weights
:param weights: Weights of each color (weights[i] = how many times color[i] appears)
:return:
"""
return [c for i, w in enumerate(weights) for c in [self.colors[i]] * w]
def with_length(self, length: int) -> list[RGB]:
"""
Spread to a specific length of text
:param length: Length of text
:return: List of RGBs of the length
"""
preset_len = len(self.colors)
center_i = preset_len // 2
# How many copies of each color should be displayed at least?
repeats = length // preset_len
weights = [repeats] * preset_len
# How many extra space left?
extras = length % preset_len
# If there is an even space left, extend the center by one space
if extras % 2 == 1:
extras -= 1
weights[center_i] += 1
# Add weight to border until there's no space left (extras must be even at this point)
border_i = 0
while extras > 0:
extras -= 2
weights[border_i] += 1
weights[-(border_i + 1)] += 1
border_i += 1
return self.with_weights(weights)
def color_text(self, txt: str, foreground: bool = True, space_only: bool = False) -> str:
"""
Color a text
:param txt: Text
:param foreground: Whether the foreground text show the color or the background block
:param space_only: Whether to only color spaces
:return: Colored text
"""
colors = self.with_length(len(txt))
result = ''
for i, t in enumerate(txt):
if space_only and t != ' ':
if i > 0 and txt[i - 1] == ' ':
result += '\033[0m'
result += t
else:
result += colors[i].to_ansi(foreground=foreground) + t
result += '\033[0m'
return result
def lighten(self, multiplier: float) -> ColorProfile:
"""
Lighten the color profile by a multiplier
:param multiplier: Multiplier
:return: Lightened color profile (original isn't modified)
"""
return ColorProfile([c.lighten(multiplier) for c in self.colors])
def set_light_raw(self, light: float, at_least: bool | None = None, at_most: bool | None = None) -> 'ColorProfile':
"""
Set HSL lightness value
:param light: Lightness value (0-1)
:param at_least: Set the lightness to at least this value (no change if greater)
:param at_most: Set the lightness to at most this value (no change if lesser)
:return: New color profile (original isn't modified)
"""
return ColorProfile([c.set_light(light, at_least, at_most) for c in self.colors])
def set_light_dl(self, light: float, term: LightDark | None = None):
"""
Set HSL lightness value with respect to dark/light terminals
:param light: Lightness value (0-1)
:param term: Terminal color (can be "dark" or "light")
:return: New color profile (original isn't modified)
"""
term = term or GLOBAL_CFG.light_dark()
assert term.lower() in ['light', 'dark']
at_least, at_most = (True, None) if term.lower() == 'dark' else (None, True)
return self.set_light_raw(light, at_least, at_most)
def set_light_dl_def(self, term: LightDark | None = None):
"""
Set default lightness with respect to dark/light terminals
:param term: Terminal color (can be "dark" or "light")
:return: New color profile (original isn't modified)
"""
return self.set_light_dl(GLOBAL_CFG.default_lightness(term), term)
def unique_colors(self) -> ColorProfile:
"""
Create another color profile with only the unique colors
"""
return ColorProfile(remove_duplicates(self.colors))
PRESETS: dict[str, ColorProfile] = {
'rainbow': ColorProfile([
'#E50000',
'#FF8D00',
'#FFEE00',
'#028121',
'#004CFF',
'#770088'
]),
'transgender': ColorProfile([
'#55CDFD',
'#F6AAB7',
'#FFFFFF',
'#F6AAB7',
'#55CDFD'
]),
'nonbinary': ColorProfile([
'#FCF431',
'#FCFCFC',
'#9D59D2',
'#282828'
]),
'agender': ColorProfile([
'#000000',
'#BABABA',
'#FFFFFF',
'#BAF484',
'#FFFFFF',
'#BABABA',
'#000000'
]),
'queer': ColorProfile([
'#B57FDD',
'#FFFFFF',
'#49821E'
]),
'genderfluid': ColorProfile([
'#FE76A2',
'#FFFFFF',
'#BF12D7',
'#000000',
'#303CBE'
]),
'bisexual': ColorProfile([
'#D60270',
'#9B4F96',
'#0038A8'
]),
'pansexual': ColorProfile([
'#FF1C8D',
'#FFD700',
'#1AB3FF'
]),
'polysexual': ColorProfile([
'#F714BA',
'#01D66A',
'#1594F6',
]),
# omnisexual sorced from https://www.flagcolorcodes.com/omnisexual
'omnisexual': ColorProfile([
'#FE9ACE',
'#FF53BF',
'#200044',
'#6760FE',
'#8EA6FF',
]),
# gay men sourced from https://www.flagcolorcodes.com/gay-men
'gay-men': ColorProfile([
'#078D70',
'#98E8C1',
'#FFFFFF',
'#7BADE2',
'#3D1A78'
]),
'lesbian': ColorProfile([
'#D62800',
'#FF9B56',
'#FFFFFF',
'#D462A6',
'#A40062'
]),
# abrosexual used colorpicker to source from
# https://fyeahaltpride.tumblr.com/post/151704251345/could-you-guys-possibly-make-an-abrosexual-pride
'abrosexual': ColorProfile([
'#46D294',
'#A3E9CA',
'#FFFFFF',
'#F78BB3',
'#EE1766',
]),
'asexual': ColorProfile([
'#000000',
'#A4A4A4',
'#FFFFFF',
'#810081'
]),
'aromantic': ColorProfile([
'#3BA740',
'#A8D47A',
'#FFFFFF',
'#ABABAB',
'#000000'
]),
# aroace1 sourced from https://flag.library.lgbt/flags/aroace/
'aroace1': ColorProfile([
'#E28C00',
'#ECCD00',
'#FFFFFF',
'#62AEDC',
'#203856'
]),
'aroace2': ColorProfile([
'#000000',
'#810081',
'#A4A4A4',
'#FFFFFF',
'#A8D47A',
'#3BA740'
]),
'aroace3': ColorProfile([
'#3BA740',
'#A8D47A',
'#FFFFFF',
'#ABABAB',
'#000000',
'#A4A4A4',
'#FFFFFF',
'#810081'
]),
# below sourced from https://www.flagcolorcodes.com/flags/pride
# goto f"https://www.flagcolorcodes.com/{preset}" for info
# todo: sane sorting
'autosexual': ColorProfile([
'#99D9EA',
'#7F7F7F'
]),
'intergender': ColorProfile([
# todo: use weighted spacing
'#900DC2',
'#900DC2',
'#FFE54F',
'#900DC2',
'#900DC2',
]),
'greygender': ColorProfile([
'#B3B3B3',
'#B3B3B3',
'#FFFFFF',
'#062383',
'#062383',
'#FFFFFF',
'#535353',
'#535353',
]),
'akiosexual': ColorProfile([
'#F9485E',
'#FEA06A',
'#FEF44C',
'#FFFFFF',
'#000000',
]),
# bigender sourced from https://www.flagcolorcodes.com/bigender
'bigender': ColorProfile([
'#C479A2',
'#EDA5CD',
'#D6C7E8',
'#FFFFFF',
'#D6C7E8',
'#9AC7E8',
'#6D82D1',
]),
# demigender yellow sourced from https://lgbtqia.fandom.com/f/p/4400000000000041031
# other colors sourced from demiboy and demigirl flags
'demigender': ColorProfile([
'#7F7F7F',
'#C4C4C4',
'#FBFF75',
'#FFFFFF',
'#FBFF75',
'#C4C4C4',
'#7F7F7F',
]),
# demiboy sourced from https://www.flagcolorcodes.com/demiboy
'demiboy': ColorProfile([
'#7F7F7F',
'#C4C4C4',
'#9DD7EA',
'#FFFFFF',
'#9DD7EA',
'#C4C4C4',
'#7F7F7F',
]),
# demigirl sourced from https://www.flagcolorcodes.com/demigirl
'demigirl': ColorProfile([
'#7F7F7F',
'#C4C4C4',
'#FDADC8',
'#FFFFFF',
'#FDADC8',
'#C4C4C4',
'#7F7F7F',
]),
'transmasculine': ColorProfile([
'#FF8ABD',
'#CDF5FE',
'#9AEBFF',
'#74DFFF',
'#9AEBFF',
'#CDF5FE',
'#FF8ABD',
]),
# transfeminine used colorpicker to source from https://www.deviantart.com/pride-flags/art/Trans-Woman-Transfeminine-1-543925985
# linked from https://gender.fandom.com/wiki/Transfeminine
'transfeminine': ColorProfile([
'#73DEFF',
'#FFE2EE',
'#FFB5D6',
'#FF8DC0',
'#FFB5D6',
'#FFE2EE',
'#73DEFF',
]),
# genderfaun sourced from https://www.flagcolorcodes.com/genderfaun
'genderfaun': ColorProfile([
'#FCD689',
'#FFF09B',
'#FAF9CD',
'#FFFFFF',
'#8EDED9',
'#8CACDE',
'#9782EC',
]),
'demifaun': ColorProfile([
'#7F7F7F',
'#7F7F7F',
'#C6C6C6',
'#C6C6C6',
'#FCC688',
'#FFF19C',
'#FFFFFF',
'#8DE0D5',
'#9682EC',
'#C6C6C6',
'#C6C6C6',
'#7F7F7F',
'#7F7F7F',
]),
# genderfae sourced from https://www.flagcolorcodes.com/genderfae
'genderfae': ColorProfile([
'#97C3A5',
'#C3DEAE',
'#F9FACD',
'#FFFFFF',
'#FCA2C4',
'#DB8AE4',
'#A97EDD',
]),
# demifae used colorpicker to source form https://www.deviantart.com/pride-flags/art/Demifae-870194777
'demifae': ColorProfile([
'#7F7F7F',
'#7F7F7F',
'#C5C5C5',
'#C5C5C5',
'#97C3A4',
'#C4DEAE',
'#FFFFFF',
'#FCA2C5',
'#AB7EDF',
'#C5C5C5',
'#C5C5C5',
'#7F7F7F',
'#7F7F7F',
]),
'neutrois': ColorProfile([
'#FFFFFF',
'#1F9F00',
'#000000'
]),
'biromantic1': ColorProfile([
'#8869A5',
'#D8A7D8',
'#FFFFFF',
'#FDB18D',
'#151638',
]),
'biromantic2': ColorProfile([
'#740194',
'#AEB1AA',
'#FFFFFF',
'#AEB1AA',
'#740194',
]),
'autoromantic': ColorProfile([ # symbol interpreted
'#99D9EA',
'#99D9EA',
'#99D9EA',
'#99D9EA',
'#99D9EA',
'#000000',
'#3DA542',
'#3DA542',
'#000000',
'#7F7F7F',
'#7F7F7F',
'#7F7F7F',
'#7F7F7F',
'#7F7F7F',
]),
# i didn't expect this one to work. cool!
'boyflux2': ColorProfile([
'#E48AE4',
'#9A81B4',
'#55BFAB',
'#FFFFFF',
'#A8A8A8',
'#81D5EF',
'#81D5EF',
'#81D5EF',
'#81D5EF',
'#81D5EF',
'#69ABE5',
'#69ABE5',
'#69ABE5',
'#69ABE5',
'#69ABE5',
'#69ABE5',
'#69ABE5',
'#69ABE5',
'#69ABE5',
'#69ABE5',
'#5276D4',
'#5276D4',
'#5276D4',
'#5276D4',
'#5276D4',
'#5276D4',
'#5276D4',
'#5276D4',
'#5276D4',
'#5276D4',
]),
'beiyang': ColorProfile([
'#DF1B12',
'#FFC600',
'#01639D',
'#FFFFFF',
'#000000',
]),
"finsexual": ColorProfile([
"#B18EDF",
"#D7B1E2",
"#F7CDE9",
"#F39FCE",
"#EA7BB3",
]),
'unlabeled1': ColorProfile([
'#EAF8E4',
'#FDFDFB',
'#E1EFF7',
'#F4E2C4'
]),
'unlabeled2': ColorProfile([
'#250548',
'#FFFFFF',
'#F7DCDA',
'#EC9BEE',
'#9541FA',
'#7D2557'
]),
'gendernonconforming1': ColorProfile(
ColorProfile([
'#50284d',
'#96467b',
'#5c96f7',
'#ffe6f7',
'#5c96f7',
'#96467b',
'#50284d'
]).with_weights([
4,1,1,1,1,1,4
])
),
'gendernonconforming2': ColorProfile([
'#50284d',
'#96467b',
'#5c96f7',
'#ffe6f7',
'#5c96f7',
'#96467b',
'#50284d'
]),
'femboy': ColorProfile([
"#d260a5",
"#e4afcd",
"#fefefe",
"#57cef8",
"#fefefe",
"#e4afcd",
"#d260a5"
]),
'tomboy': ColorProfile([
"#2f3fb9",
"#613a03",
"#fefefe",
"#f1a9b7",
"#fefefe",
"#613a03",
"#2f3fb9"
]),
}

1
hyfetch/scripts/neowofetch Symbolic link
View file

@ -0,0 +1 @@
../../neofetch

48
hyfetch/serializer.py Normal file
View file

@ -0,0 +1,48 @@
from __future__ import annotations
import dataclasses
import inspect
import json
from datetime import datetime, date
class EnhancedJSONEncoder(json.JSONEncoder):
"""
An improvement to the json.JSONEncoder class, which supports:
encoding for dataclasses, encoding for datetime, and sets
"""
def default(self, o: object) -> object:
# Support encoding dataclasses
# https://stackoverflow.com/a/51286749/7346633
if dataclasses.is_dataclass(o):
return dataclasses.asdict(o)
# Support encoding datetime
if isinstance(o, (datetime, date)):
return o.isoformat()
# Support for sets
# https://stackoverflow.com/a/8230505/7346633
if isinstance(o, set):
return list(o)
return super().default(o)
def json_stringify(obj: object, indent: int | None = None) -> str:
"""
Serialize json string with support for dataclasses and datetime and sets and with custom
configuration.
Preconditions:
- obj != None
:param obj: Objects
:param indent: Indent size or none
:return: Json strings
"""
return json.dumps(obj, indent=indent, cls=EnhancedJSONEncoder, ensure_ascii=False)
def from_dict(cls, d: dict):
return cls(**{k: v for k, v in d.items() if k in inspect.signature(cls).parameters})

169
hyfetch/termenv.py Normal file
View file

@ -0,0 +1,169 @@
from __future__ import annotations
import os
import platform
import sys
from .color_util import RGB, AnsiMode
class OSCException(Exception):
pass
def unix_detect_ansi_mode() -> AnsiMode | None:
"""
Translated from Termenv's ColorProfile():
https://github.com/muesli/termenv/blob/42ca574de3e99a262e1724d2fb8daa1aea68a5b9/termenv_unix.go#L23
:return: Ansi mode
"""
if not sys.stdout.isatty():
return 'ansi'
term = os.environ.get('TERM')
color_term = os.environ.get('COLORTERM')
if color_term == 'truecolor' or color_term == '24bit':
if term.startswith('screen') and os.environ.get('TERM_PROGRAM') != 'tmux':
return '8bit'
return 'rgb'
elif color_term == 'true' or color_term == 'yes':
return '8bit'
if term == 'xterm-kitty':
return 'rgb'
elif term == 'linux':
return 'ansi'
if '256color' in term:
return 'rgb'
if 'color' in term:
return '8bit'
if 'ansi' in term:
return 'ansi'
return None
def windows_detect_ansi_mode() -> AnsiMode | None:
"""
Translated from Termenv's ColorProfile():
https://github.com/muesli/termenv/blob/42ca574de3e99a262e1724d2fb8daa1aea68a5b9/termenv_windows.go#L13
:return: Ansi mode
"""
if not sys.stdout.isatty():
return 'ansi'
if os.environ.get("ConEmuANSI") == "ON":
return 'rgb'
release, _, build = map(int, platform.version().split('.'))
if build < 10586 or release < 10:
# No ANSI support before Windows 10 build 10586.
if os.environ.get('ANSICON'):
conv = os.environ.get('ANSICON_VER')
if int(conv) < 181:
return 'ansi'
return '8bit'
return 'ansi'
if build < 14931:
# No true color support before build 14931.
return '8bit'
return 'rgb'
def detect_ansi_mode() -> AnsiMode | None:
system = platform.system().lower()
if system.startswith("linux") or system.startswith("darwin"):
return unix_detect_ansi_mode()
if system.startswith("windows"):
return windows_detect_ansi_mode()
return None
def unix_read_osc(seq: int) -> str:
import termios
import tty
import signal
from select import select
# screen/tmux can't support OSC, because they can be connected to multiple
# terminals concurrently.
term = os.environ.get('TERM')
if term.startswith("screen") or term.startswith("tmux"):
raise OSCException("Screen/tmux not supported")
t = sys.stdout
if not t.isatty():
raise OSCException("Not a tty")
fd = sys.stdin.fileno()
# Set raw mode
settings = termios.tcgetattr(fd)
tty.setraw(sys.stdin.fileno())
# first, send OSC query, which is ignored by terminal which do not support it
t.write(f"\x1b]{seq};?\x1b\\")
t.flush()
# stdin response timeout should be higher for ssh sessions
timeout = 0.05 if (os.environ.get('SSH_TTY') or os.environ.get('SSH_SESSION')) is None else 0.5
# Wait for input to appear
if not select([sys.stdin], [], [], timeout)[0]:
# Reset terminal back to normal mode (previously set to raw mode)
termios.tcsetattr(fd, termios.TCSADRAIN, settings)
raise OSCException("No response received")
# Read until termination, or if it doesn't terminate, read until 1 second passes
def handler(signum, frame):
raise IOError()
signal.signal(signal.SIGALRM, handler)
signal.setitimer(signal.ITIMER_REAL, timeout, 1)
code = ""
try:
for _ in range(28):
code += sys.stdin.read(1)
# Terminate with sequence terminator [\ or bell ^G
if code.endswith('\x1b\\') or code.endswith('\a'):
break
signal.alarm(0)
except IOError:
pass
# Reset terminal back to normal mode (previously set to raw mode)
termios.tcsetattr(fd, termios.TCSADRAIN, settings)
# Validate output
if not code:
raise OSCException("No response received")
start = f"\x1b]{seq};"
if not code.startswith(start):
raise OSCException("Received response is not an OSC response")
# Strip starting code and termination code
code = code.lstrip(start).rstrip("\x1b\\").rstrip('\a')
return code
def get_background_color() -> RGB | None:
system = platform.system().lower()
if system.startswith("linux") or system.startswith("darwin"):
try:
osc = unix_read_osc(11).lstrip("rgb:")
return RGB.from_hex(''.join([v[:2] for v in osc.split('/')]))
except Exception:
return None
if system.startswith("windows"):
return None

3163
neofetch

File diff suppressed because it is too large Load diff

View file

@ -1,7 +1,7 @@
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.48.3.
.TH NEOFETCH "1" "April 2021" "Neofetch 7.1.0" "User Commands"
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.49.2.
.TH NEOFETCH "1" "November 2022" "Neofetch 7.3.4" "User Commands"
.SH NAME
Neofetch \- A fast, highly customizable system info script
Neofetch \- manual page for Neofetch 7.3.4
.SH SYNOPSIS
.B neofetch
\fI\,func_name --option "value" --option "value"\/\fR
@ -44,7 +44,7 @@ NOTE: You can supply multiple args. eg. 'neofetch \fB\-\-disable\fR cpu gpu'
Hide/Show Fully Qualified Domain Name in title.
.TP
\fB\-\-package_managers\fR on/off
Hide/Show Package Manager names . (on, tiny, off)
Hide/Show Package Manager names. (on, tiny, off)
.TP
\fB\-\-os_arch\fR on/off
Hide/Show OS architecture.
@ -164,9 +164,12 @@ Print the Artist/Album/Title on separate lines.
\fB\-\-memory_percent\fR on/off
Display memory percentage.
.TP
\fB\-\-memory_unit\fR kib/mib/gib
\fB\-\-memory_unit\fR (k/m/g/t)ib
Memory output unit.
.TP
\fB\-\-memory_precision\fR integer
Change memory output precision. (???0, default=2)
.TP
\fB\-\-music_player\fR player\-name
Manually specify a player to use.
Available values are listed in the config file
@ -301,52 +304,58 @@ Colors to print the ascii art
\fB\-\-ascii_distro\fR distro
Which Distro's ascii art to print
.TP
NOTE: AIX, Hash, Alpine, AlterLinux, Amazon, Anarchy, Android, instantOS,
Antergos, antiX, "AOSC OS", "AOSC OS/Retro", Apricity, ArchCraft,
ArcoLinux, ArchBox, ARCHlabs, ArchStrike, XFerience, ArchMerge, Arch,
Artix, Arya, Bedrock, Bitrig, BlackArch, BLAG, BlankOn, BlueLight,
bonsai, BSD, BunsenLabs, Calculate, Carbs, CentOS, Chakra, ChaletOS,
Chapeau, Chrom*, Cleanjaro, ClearOS, Clear_Linux, Clover, Condres,
Container_Linux, CRUX, Cucumber, dahlia, Debian, Deepin, DesaOS,
Devuan, DracOS, DarkOs, Itc, DragonFly, Drauger, Elementary,
EndeavourOS, Endless, EuroLinux, Exherbo, Fedora, Feren, FreeBSD,
FreeMiNT, Frugalware, Funtoo, GalliumOS, Garuda, Gentoo, Pentoo,
gNewSense, GNOME, GNU, GoboLinux, Grombyang, Guix, Haiku, Huayra, HydroOS,
Hyperbola, janus, Kali, KaOS, KDE_neon, Kibojoe, Kogaion, Korora,
KSLinux, Kubuntu, LEDE, LaxerOS, LibreELEC, LFS, Linux_Lite, LMDE,
Lubuntu, Lunar, macos, Mageia, MagpieOS, Mandriva, Manjaro, TeArch, Maui,
Mer, Minix, LinuxMint, Live_Raizo, MX_Linux, Namib, Neptune, NetBSD,
Netrunner, Nitrux, NixOS, Nurunner, NuTyX, OBRevenge, OpenBSD,
openEuler, OpenIndiana, openmamba, OpenMandriva, OpenStage, OpenWrt,
osmc, Oracle, OS Elbrus, PacBSD, Parabola, Pardus, Parrot, Parsix,
TrueOS, PCLinuxOS, Pengwin, Peppermint, Pisi, popos, Porteus, PostMarketOS,
Proxmox, Puppy, PureOS, Qubes, Quibian, Radix, Raspbian, Reborn_OS,
Redstar, Redcore, Redhat, Refracted_Devuan, Regata, Regolith, Rosa,
sabotage, Sabayon, Sailfish, SalentOS, Scientific, Septor,
SereneLinux, SharkLinux, Siduction, Slackware, SliTaz, SmartOS,
Solus, Source_Mage, Sparky, Star, SteamOS, SunOS, openSUSE_Leap,
t2, openSUSE_Tumbleweed, openSUSE, SwagArch, Tails, Trisquel,
Ubuntu\-Cinnamon, Ubuntu\-Budgie, Ubuntu\-GNOME, Ubuntu\-MATE,
Ubuntu\-Studio, Ubuntu, Univention, Venom, Void, VNux, semc, Obarun,
windows10, Windows7, Xubuntu, Zorin, and IRIX have ascii logos.
.IP
NOTE: Arch, Ubuntu, Redhat, Fedora and Dragonfly have 'old' logo variants.
.IP
NOTE: Use '{distro name}_old' to use the old logos.
.IP
NOTE: Ubuntu has flavor variants.
NOTE: AIX, AlmaLinux, Alpine, Alter, Amazon, AmogOS, Anarchy,
Android, Antergos, antiX, AOSC OS, AOSC OS/Retro, Aperio GNU/Linux,
Apricity, Arch, ArchBox, Archcraft, ARCHlabs, ArchStrike, ArcoLinux,
Artix, Arya, Asahi, AsteroidOS, astOS, Bedrock, BigLinux, Bitrig,
BlackArch, blackPanther, BLAG, BlankOn, BlueLight, Bodhi, bonsai,
BSD, BunsenLabs, Cachy OS, Calculate, CalinixOS, Carbs, CBL\-Mariner,
CelOS, Center, CentOS, Chakra, ChaletOS, Chapeau, ChonkySealOS,
Chrom, Cleanjaro, Clear Linux OS, ClearOS, Clover, Cobalt, Condres,
Container Linux by CoreOS, CRUX, Crystal Linux, Cucumber,
CutefishOS, CyberOS, dahlia, DarkOs, Darwin, Debian, Deepin, DesaOS,
Devuan, DietPi, DracOS, DragonFly, Drauger, Droidian, Elementary,
Elive, EncryptOS, EndeavourOS, Endless, Enso, EuroLinux, Exherbo,
Exodia Predator OS, Fedora, Feren, Finnix, FreeBSD, FreeMiNT,
Frugalware, Funtoo, GalliumOS, Garuda, Gentoo, GhostBSD, glaucus,
gNewSense, GNOME, GNU, GoboLinux, GrapheneOS, Grombyang, Guix,
Haiku, HamoniKR, HarDClanZ, Hash, Huayra, HydroOS, Hyperbola,
iglunix, instantOS, IRIX, Itc, januslinux, Kaisen, Kali, KaOS, KDE,
Kibojoe, Kogaion, Korora, KrassOS, KSLinux, Kubuntu, LangitKetujuh,
LaxerOS, LEDE, LibreELEC, Linspire, Linux, Linux Lite, Linux Mint,
Linux Mint Old, Live Raizo, LMDE, Lubuntu, Lunar, mac, Mageia,
MagpieOS, Mandriva, Manjaro, MassOS, MatuusOS, Maui, Mer, Minix,
MIRACLE LINUX, MX, Namib, Neptune, NetBSD, Netrunner, Nitrux, NixOS,
NomadBSD, Nurunner, NuTyX, Obarun, OBRevenge, OmniOS, Open Source
Media Center, OpenBSD, openEuler, OpenIndiana, openmamba,
OpenMandriva, OpenStage, openSUSE, openSUSE Leap, openSUSE
Tumbleweed, OpenWrt, OPNsense, Oracle, orchid, OS Elbrus, PacBSD,
Parabola, parch, Pardus, Parrot, Parsix, PCBSD, PCLinuxOS, pearOS,
Pengwin, Pentoo, Peppermint, Pisi, PNM Linux, Pop!_OS, Porteus,
PostMarketOS, Profelis SambaBOX, Proxmox, PuffOS, Puppy, PureOS,
Q4OS, Qubes, Qubyt, Quibian, Radix, Raspbian, ravynOS, Reborn OS,
Red Star, Redcore, Redhat, Refracted Devuan, Regata, Regolith,
rocky, Rosa, Sabayon, sabotage, Sailfish, SalentOS, Scientific,
semc, Septor, Serene, SharkLinux, ShastraOS, Siduction, SkiffOS,
Slackware, SliTaz, SmartOS, Soda, Solus, Source Mage, Sparky, Star,
SteamOS, Stock Linux, Sulin, SunOS, SwagArch, t2, Tails, TeArch,
TorizonCore, Trisquel, Twister, Ubuntu, Ubuntu Budgie, Ubuntu
Cinnamon, Ubuntu Kylin, Ubuntu MATE, Ubuntu Studio, Ubuntu Sway,
Ubuntu Touch, Ubuntu\-GNOME, ubuntu_old02, Ultramarine Linux,
Univalent, Univention, Uos, uwuntu, Vanilla, Venom, VNux, Void,
VzLinux, wii\-linux\-ngx, Windows, Windows 10, Windows 11, XFerience,
Xubuntu, yiffOS, Zorin have ascii logos.
.TP
NOTE: Change this to Lubuntu, Kubuntu, Xubuntu, Ubuntu\-GNOME,
Ubuntu\-Studio, Ubuntu\-Mate or Ubuntu\-Budgie to use the flavors.
NOTE: arch, dragonfly, Fedora, LangitKetujuh, nixos, redhat, Ubuntu
have 'old' logo variants, use {distro}_old to use them.
.TP
NOTE: Arcolinux, Dragonfly, Fedora, Alpine, Arch, Ubuntu,
CRUX, Debian, Gentoo, FreeBSD, Mac, NixOS, OpenBSD, android,
Artix, CentOS, Cleanjaro, ElementaryOS, GUIX, Hyperbola,
Manjaro, MXLinux, NetBSD, Parabola, POP_OS, PureOS,
Slackware, SunOS, LinuxLite, OpenSUSE, Raspbian,
postmarketOS, and Void have a smaller logo variant.
.IP
NOTE: Use '{distro name}_small' to use the small variants.
NOTE: alpine, android, aoscosretro, arch, arcolinux, artix,
CalinixOS, centos, cleanjaro, crux, debian, dragonfly, elementary,
fedora, freebsd, garuda, gentoo, guix, haiku, hyperbola, linuxlite,
linuxmint, mac, mageia, manjaro, mx, netbsd, nixos, openbsd,
opensuse, orchid, parabola, popos, postmarketos, pureos, Raspbian,
rocky, slackware, sunos, ubuntu, void have 'small' logo variants,
use {distro}_small to use them.
.TP
\fB\-\-ascii_bold\fR on/off
Whether or not to bold the ascii logo.
@ -409,9 +418,18 @@ Don't create the user config file.
\fB\-\-print_config\fR
Print the default config file to stdout.
.TP
\fB\-\-stdout\fR
\fB\-\-stdout\fR=\fI\,on\/\fR
Turn off all colors and disables any ASCII/image backend.
.TP
\fB\-\-stdout\fR=\fI\,off\/\fR
Enable the colored output and ASCII/image backend
.TP
\fB\-\-stdout\fR=\fI\,auto\/\fR
Let the program decide basing on the output type (default behavior)
.TP
\fB\-\-stdout\fR
Equivalent to '\-\-stdout=on', for backward compatibility
.TP
\fB\-\-help\fR
Print this text and exit
.TP
@ -429,3 +447,15 @@ Display a verbose log for error reporting.
Generate a manpage for Neofetch in your PWD. (Requires GNU help2man)
.SH "REPORTING BUGS"
Report bugs to https://github.com/dylanaraps/neofetch/issues
.SH "SEE ALSO"
The full documentation for
.B Neofetch
is maintained as a Texinfo manual. If the
.B info
and
.B Neofetch
programs are properly installed at your site, the command
.IP
.B info Neofetch
.PP
should give you access to the complete manual.

25
package.json Normal file
View file

@ -0,0 +1,25 @@
{
"name": "neowofetch",
"version": "1.4.4",
"description": "Updated neofetch",
"repository": {
"type": "git",
"url": "git+https://github.com/hykilpikonna/neofetch.git"
},
"bin": {
"neowofetch": "neofetch"
},
"keywords": [
"neofetch",
"screenfetch"
],
"author": "dylanaraps",
"contributors": [
"Azalea Gui <me@hydev.org> (https://github.com/hykilpikonna)"
],
"license": "MIT",
"bugs": {
"url": "https://github.com/hykilpikonna/neofetch/issues"
},
"homepage": "https://github.com/hykilpikonna/neofetch#readme"
}

6
runner.py Executable file
View file

@ -0,0 +1,6 @@
#!/usr/bin/env python3
import hyfetch
if __name__ == '__main__':
hyfetch.main.run()

49
setup.py Executable file
View file

@ -0,0 +1,49 @@
#!/usr/bin/env python3
import pathlib
from setuptools import setup
import hyfetch.constants
# The directory containing this file
HERE = pathlib.Path(__file__).parent
# The text of the README file
README = (HERE / "README.md").read_text('utf-8')
# This call to setup() does all the work
setup(
name="HyFetch",
version=hyfetch.constants.VERSION,
description="neofetch with flags <3",
long_description=README,
long_description_content_type="text/markdown",
url="https://github.com/hykilpikonna/HyFetch",
author="Azalea Gui",
author_email="me@hydev.org",
license="MIT",
classifiers=[
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
],
packages=['hyfetch'],
package_data={'hyfetch': ['hyfetch/*']},
include_package_data=True,
install_requires=[
# Universal dependencies
'setuptools', 'typing_extensions',
# Windows dependencies
'psutil ; platform_system=="Windows"',
],
entry_points={
"console_scripts": [
"hyfetch=hyfetch.main:run",
]
},
scripts=['hyfetch/scripts/neowofetch']
)

68
test.py Normal file
View file

@ -0,0 +1,68 @@
from __future__ import annotations
import sys
import time
from dataclasses import dataclass
from pathlib import Path
from urllib.request import urlretrieve
from hyfetch.color_util import printc, color
from hyfetch.neofetch_util import term_size
@dataclass
class Theme:
done_char: str
todo_char: str
prefix: str = ''
suffix: str = ''
done_len: int = 1
todo_len: int = 1
CLASSIC_THEME = Theme('', '.', '[', ']')
NEW_THEME = Theme('&a━', '&c━')
EMOJI_THEME = Theme('', '🕑', done_len=2, todo_len=2)
EGG_THEME = Theme('🐣', '🥚', done_len=2, todo_len=2)
FLOWER_THEME = Theme('🌸', '🥀', done_len=2, todo_len=2)
def print_progressbar(total: int, i: int, length: int | None = None, theme: Theme = EMOJI_THEME, unit=''):
if not length:
length = term_size()[0]
i += 1
completed = f'{i * 100 / total:.0f}%'
placeholder = 'PLACEHOLDER_BAR'
template = f'{theme.prefix}{placeholder}{theme.suffix}&r {completed} {i}/{total}{unit}'
length -= len(template) - len(placeholder) + 2
progress = int(i / total * length)
bar = f'{theme.done_char * (progress // theme.todo_len)}{theme.todo_char * ((length - progress) // theme.done_len)}'
print(color(template.replace(placeholder, bar)), end='\r', flush=True)
def download_pbar(url: str, path: Path):
def hook(b: int, bsize: int, tsize: int):
print_progressbar(tsize // 1024 // 1024, b * bsize // 1024 // 1024, unit=' MB')
if path.is_dir():
filename = url.split('/')[-1]
path = path / filename
path.parent.mkdir(exist_ok=True, parents=True)
urlretrieve(url, filename=path, reporthook=hook)
print()
if __name__ == '__main__':
# theme = {'emoji': EMOJI_THEME, 'flower': FLOWER_THEME, 'egg': EGG_THEME, 'classic': CLASSIC_THEME, 'new': NEW_THEME}
#
# for name, t in theme.items():
# print(f'\n{name} theme:')
# for i in range(100):
# print_progressbar(100, i, theme=t)
# time.sleep(0.015)
# print()
download_pbar('https://github.com/git-for-windows/git/releases/download/v2.37.2.windows.2/MinGit-2.37.2.2-busybox-64-bit.zip', Path('Downloads'))

102
tools/accept_upstream.py Executable file
View file

@ -0,0 +1,102 @@
#!/usr/bin/env python3
import argparse
import os
import shlex
from subprocess import check_output
import pyperclip
import requests
from github import Github
upstream = 'dylanaraps/neofetch'
my_fork = 'hykilpikonna/hyfetch'
my_base = 'master'
http = requests.Session()
if 'GH_TOKEN' in os.environ:
print('Token loaded')
http.headers['Authorization'] = f'token {os.environ["GH_TOKEN"]}'
def copy_comment():
# Get commit SHA
sha = check_output(shlex.split('git rev-parse --short HEAD')).decode().strip()
# Copy comment to clipboard
comment = f"""
Thank you for your contribution!
This PR is [merged into hyfetch](https://github.com/hykilpikonna/hyfetch/commit/{sha}) since this repo (dylanaraps/neofetch) seems no longer maintained.
[HyFetch](https://github.com/hykilpikonna/hyfetch) is a fork of neofetch with LGBTQ pride flags, but the repo also maintains an updated version of the original neofetch, addressing many pull requests that are not merged in the original repo.
Read the ["Running Updated Original Neofetch" section](https://github.com/hykilpikonna/hyfetch#running-updated-original-neofetch) for more info!
"""
pyperclip.copy(comment.strip())
print()
print('Done!')
print('Comment response copied to clipboard.')
if __name__ == '__main__':
parser = argparse.ArgumentParser(description='Helper for accepting upstream pull requests')
parser.add_argument('pull', type=int, help='Pull request number')
args = parser.parse_args()
pr = args.pull
print(f'Accepting pull request {pr}...')
# Fetch original pr's information
info = http.get(f'https://api.github.com/repos/{upstream}/pulls/{pr}').json()
user = info['user']['login']
# Fetch commit information
commits = http.get(f'https://api.github.com/repos/{upstream}/pulls/{pr}/commits').json()
author = commits[0]['commit']['author']
# Create commit message
title = info["title"].replace('"', '\\"')
msg = (f'-m "[PR] {upstream}#{pr} from {user} - {title}" '
f'-m "Upstream PR: https://github.com/{upstream}/pull/{pr} \n'
f'Thanks to @{user}\n\n'
f'Co-authored-by: {author["name"]} <{author["email"]}>"')
# head could be null, if the pr repo is deleted
if info['head'] is None or info['head']['repo'] is None:
print(f'Original repo is deleted. Please manually merge.')
input('Press any key to continue when the changes are made...')
# Commit with merge
print()
print('Committing merge...')
os.system(f'git commit -a {msg}')
# Automatically merge
else:
head = info['head']['repo']['full_name']
head_br = info['head']['ref']
head_lbl = info['head']['label']
print()
print('Original Pull Request Info:')
print('> State:', info['state'])
print('> Title:', info['title'])
print('> User:', user)
print('> Created:', info['created_at'])
print('> Head:', head, head_br, head_lbl)
# Fetch head branch
print()
print('Fetching head branch...')
os.system(f'git fetch https://github.com/{head} {head_br}')
# Merge head branch
print()
print('Merging fetch_head...')
os.system(f'git merge FETCH_HEAD --no-ff --no-edit {msg}')
# Push
print()
assert input('Push? [Enter/N]') == ""
os.system('git push')
copy_comment()

39
tools/colors_test.py Executable file
View file

@ -0,0 +1,39 @@
from hyfetch.color_scale import test_color_scale
from hyfetch.color_util import RGB, printc
from hyfetch.neofetch_util import get_command_path, run_neofetch
from hyfetch.presets import PRESETS
def print_colors_test(colors: list[RGB]):
print(''.join(f'{c.to_ansi_rgb()}#' for c in colors))
def test_preset_length():
p = PRESETS.get('transgender')
print_colors_test(p.with_length(9))
print_colors_test(p.with_length(6))
p = PRESETS.get('nonbinary')
print_colors_test(p.with_length(7))
print_colors_test(p.with_length(6))
def test_command_path():
print(get_command_path())
def test_rgb_8bit_conversion():
for r in range(0, 255, 16):
for g in range(0, 255, 16):
print(RGB(r, g, 0).to_ansi_rgb(False), end=' ')
printc('&r')
print()
for r in range(0, 255, 16):
for g in range(0, 255, 16):
print(RGB(r, g, 0).to_ansi_8bit(False), end=' ')
printc('&r')
print()
if __name__ == '__main__':
test_rgb_8bit_conversion()
test_color_scale()

163
tools/deploy-release.py Executable file
View file

@ -0,0 +1,163 @@
#!/usr/bin/env python3
import argparse
import json
import os
import re
import shlex
import stat
import subprocess
import sys
from pathlib import Path
from packaging import version as pv
sys.path.append(str(Path(__file__).parent.parent))
from tools.list_distros import generate_help
from tools.reformat_readme import reformat_readme
NEOFETCH_NEW_VERSION = ""
def pre_check():
"""
Check source code status before releasing.
"""
assert os.path.isfile('./neofetch'), './neofetch doesn\'t exist, you are running this script in the wrong directory'
assert os.stat('./neofetch').st_mode & stat.S_IEXEC, 'neofetch is not executable'
assert os.path.islink('./hyfetch/scripts/neowofetch'), 'neowofetch is not a symbolic link'
# subprocess.check_call(shlex.split('git diff-index --quiet HEAD --')) # 'Please commit all changes before release'
subprocess.check_call(shlex.split('shellcheck neofetch'))
def edit_versions(version: str):
"""
Edit version numbers in hyfetch/constants.py, package.json, and README.md
Also edits version number of neofetch, but the neofetch version number is separate.
:param version: Version to release
"""
# 1. package.json
print('Editing package.json...')
path = Path('package.json')
content = json.loads(path.read_text())
cur = pv.parse(content['version'])
assert cur < pv.parse(version), 'Version did not increase'
content['version'] = version
path.write_text(json.dumps(content, ensure_ascii=False, indent=2))
# 2. hyfetch/constants.py
print('Editing hyfetch/constants.py...')
path = Path('hyfetch/constants.py')
content = [f"VERSION = '{version}'" if l.startswith('VERSION = ') else l for l in path.read_text().split('\n')]
path.write_text('\n'.join(content))
# 3. README.md
print('Editing README.md...')
path = Path('README.md')
content = path.read_text()
changelog_i = content.index('<!-- CHANGELOG STARTS HERE --->')
version_i = content.index('###', changelog_i)
version_end = content.index('\n', version_i)
content = content[:version_i] + f'### {version}' + content[version_end:]
path.write_text(content)
# 4. neofetch script
print('Editing neofetch...')
path = Path('neofetch')
lines = path.read_text().split('\n')
version_i = next(i for i, l in enumerate(lines) if l.startswith('version='))
nf = pv.parse(lines[version_i].replace('version=', ''))
new = pv.parse(version)
nf = f'{nf.major + new.major - cur.major}.{nf.minor + new.minor - cur.minor}.{nf.micro + new.micro - cur.micro}'
lines[version_i] = f"version={nf}"
path.write_text('\n'.join(lines))
global NEOFETCH_NEW_VERSION
NEOFETCH_NEW_VERSION = nf
def finalize_neofetch():
"""
Finalize current version
"""
# 1. Update distro list
print('Updating distro list in neofetch...')
path = Path('neofetch')
content = path.read_text()
content = re.compile(r'(?<=# Flag: --ascii_distro\n#\n).*?(?=ascii_distro=)', re.DOTALL)\
.sub(generate_help(100, '# ') + '\n', content)
content = re.compile(r"""(?<=Which Distro's ascii art to print\n\n).*?{distro}_small to use them\.""", re.DOTALL)\
.sub(generate_help(100, ' ' * 32), content)
path.write_text(content)
# 2. Regenerate man page
print('Regenerating neofetch man page...')
Path('neofetch.1').write_text(subprocess.check_output(['help2man', './neofetch']).decode())
# 3. Reformat readme links
print('Reformatting readme links...')
reformat_readme()
def post_check():
"""
Check after changes are made
"""
subprocess.check_call(shlex.split('shellcheck neofetch'))
def create_release(v: str):
"""
Create release commit and tag
"""
print('Committing changes...')
# 1. Add files
subprocess.check_call(['git', 'add', 'hyfetch/constants.py', 'neofetch', 'neofetch.1', 'package.json', 'README.md'])
# 2. Commit
subprocess.check_call(['git', 'commit', '-m', f'[U] Release {v}'])
# 3. Create tag
subprocess.check_call(['git', 'tag', v])
subprocess.check_call(['git', 'tag', f'neofetch-{NEOFETCH_NEW_VERSION}'])
i = input('Please check the commit is correct. Press y to continue or any other key to cancel.')
assert i == 'y'
# 4. Push
print('Pushing commits...')
subprocess.check_call(['git', 'push'])
subprocess.check_call(['git', 'push', 'origin', v])
def deploy():
"""
Deploy release to pip and npm
"""
print('Deploying to pypi...')
subprocess.check_call(['bash', 'tools/deploy.sh'])
print('Done!')
print('Deploying to npm...')
otp = input('Please provide 2FA OTP for NPM: ')
subprocess.check_call(['npm', 'publish', '--otp', otp])
print('Done!')
if __name__ == '__main__':
parser = argparse.ArgumentParser(description='HyFetch Release Utility')
parser.add_argument('version', help='Version to release')
args = parser.parse_args()
pre_check()
edit_versions(args.version)
finalize_neofetch()
post_check()
create_release(args.version)
deploy()

11
tools/deploy.md Normal file
View file

@ -0,0 +1,11 @@
### Things to do before deploying...
* [x] Check file permissions (+x)
* [x] Check Shellcheck (should be automatic)
* [x] Update version numbers (`README.md`, `package.json`, `hyfetch/constants.py`, `neofetch`)
* [x] Update distro list in neofetch help (`tools/list_distros.py`)
* [x] Regenerate man page (`help2man ./neofetch > neofetch.1`)
* [ ] Create an RC release and deploy to pypi, try installing and testing on many distros.
* [ ] Change back to stable release, create tag, create GitHub release
* [x] Formally deploy to pypi and npm (`tools/deploy.sh`, `npm publish`)
* [ ] Update ArchLinux AUR and NixOS packaging

17
tools/deploy.sh Executable file
View file

@ -0,0 +1,17 @@
#!/usr/bin/env bash
# Stop on error
set -e
# Remove old build
rm -rf dist/*
rm -rf build/*
# Build
python setup.py sdist bdist_wheel
# Check built files
twine check dist/*
# Upload
twine upload dist/*

26
tools/distros/aix.py Normal file
View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
aix = AsciiArt(match=r'''"AIX"*''', color='2 7', ascii=r"""
${c1} `:+ssssossossss+-`
.oys///oyhddddhyo///sy+.
/yo:+hNNNNNNNNNNNNNNNNh+:oy/
:h/:yNNNNNNNNNNNNNNNNNNNNNNy-+h:
`ys.yNNNNNNNNNNNNNNNNNNNNNNNNNNy.ys
`h+-mNNNNNNNNNNNNNNNNNNNNNNNNNNNNm-oh
h+-NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN.oy
/d`mNNNNNNN/::mNNNd::m+:/dNNNo::dNNNd`m:
h//NNNNNNN: . .NNNh mNo od. -dNNNNN:+y
N.sNNNNNN+ -N/ -NNh mNNd. sNNNNNNNo-m
N.sNNNNNs +oo /Nh mNNs` ` /mNNNNNNo-m
h//NNNNh ossss` +h md- .hm/ `sNNNNN:+y
:d`mNNN+/yNNNNNd//y//h//oNNNNy//sNNNd`m-
yo-NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNm.ss
`h+-mNNNNNNNNNNNNNNNNNNNNNNNNNNNNm-oy
sy.yNNNNNNNNNNNNNNNNNNNNNNNNNNs.yo
:h+-yNNNNNNNNNNNNNNNNNNNNNNs-oh-
:ys:/yNNNNNNNNNNNNNNNmy/:sy:
.+ys///osyhhhhys+///sy+.
-/osssossossso/-
""")

View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
almalinux = AsciiArt(match=r'''"AlmaLinux"*''', color='1 3 4 2 6', ascii=r"""
${c1} 'c:.
${c1} lkkkx, .. ${c2}.. ,cc,
${c1} okkkk:ckkx' ${c2}.lxkkx.okkkkd
${c1} .:llcokkx' ${c2}:kkkxkko:xkkd,
${c1} .xkkkkdood: ${c2};kx, .lkxlll;
${c1} xkkx. ${c2}xk' xkkkkk:
${c1} 'xkx. ${c2}xd .....,.
${c3} .. ${c1}:xkl' ${c2}:c ..''..
${c3} .dkx' ${c1}.:ldl:'. ${c2}' ${c4}':lollldkkxo;
${c3} .''lkkko' ${c4}ckkkx.
${c3}'xkkkd:kkd. .. ${c5};' ${c4}:kkxo.
${c3},xkkkd;kk' ,d; ${c5}ld. ${c4}':dkd::cc,
${c3} .,,.;xkko'.';lxo. ${c5}dx, ${c4}:kkk'xkkkkc
${c3} 'dkkkkkxo:. ${c5};kx ${c4}.kkk:;xkkd.
${c3} ..... ${c5}.;dk:. ${c5}lkk. ${c4}:;,
${c5}:kkkkkkkdoxkkx
,c,,;;;:xkkd.
;kkkkl...
;kkkkl
,od;
""")

26
tools/distros/alpine.py Normal file
View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
alpine = AsciiArt(match=r'''"Alpine"*''', color='4 5 7 6', ascii=r"""
${c1} .hddddddddddddddddddddddh.
:dddddddddddddddddddddddddd:
/dddddddddddddddddddddddddddd/
+dddddddddddddddddddddddddddddd+
`sdddddddddddddddddddddddddddddddds`
`ydddddddddddd++hdddddddddddddddddddy`
.hddddddddddd+` `+ddddh:-sdddddddddddh.
hdddddddddd+` `+y: .sddddddddddh
ddddddddh+` `//` `.` -sddddddddd
ddddddh+` `/hddh/` `:s- -sddddddd
ddddh+` `/+/dddddh/` `+s- -sddddd
ddd+` `/o` :dddddddh/` `oy- .yddd
hdddyo+ohddyosdddddddddho+oydddy++ohdddh
.hddddddddddddddddddddddddddddddddddddh.
`yddddddddddddddddddddddddddddddddddy`
`sdddddddddddddddddddddddddddddddds`
+dddddddddddddddddddddddddddddd+
/dddddddddddddddddddddddddddd/
:dddddddddddddddddddddddddd:
.hddddddddddddddddddddddh.
""")

View file

@ -0,0 +1,12 @@
from hyfetch.distro import AsciiArt
alpine_small = AsciiArt(match=r'''"alpine_small"''', color='4 7', ascii=r"""
${c1} /\\ /\\
/${c2}/ ${c1}\\ \\
/${c2}/ ${c1}\\ \\
/${c2}// ${c1}\\ \\
${c2}// ${c1}\\ \\
\\
""")

26
tools/distros/alter.py Normal file
View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
alter = AsciiArt(match=r'''"Alter"*''', color='6 6', ascii=r"""
${c1} %,
^WWWw
'wwwwww
!wwwwwwww
#`wwwwwwwww
@wwwwwwwwwwww
wwwwwwwwwwwwwww
wwwwwwwwwwwwwwwww
wwwwwwwwwwwwwwwwwww
wwwwwwwwwwwwwwwwwwww,
w~1i.wwwwwwwwwwwwwwwww,
3~:~1lli.wwwwwwwwwwwwwwww.
:~~:~?ttttzwwwwwwwwwwwwwwww
#<~:~~~~?llllltO-.wwwwwwwwwww
#~:~~:~:~~?ltlltlttO-.wwwwwwwww
@~:~~:~:~:~~(zttlltltlOda.wwwwwww
@~:~~: ~:~~:~:(zltlltlO a,wwwwww
8~~:~~:~~~~:~~~~_1ltltu ,www
5~~:~~:~~:~~:~~:~~~_1ltq N,,
g~:~~:~~~:~~:~~:~:~~~~1q N,
""")

25
tools/distros/amazon.py Normal file
View file

@ -0,0 +1,25 @@
from hyfetch.distro import AsciiArt
amazon = AsciiArt(match=r'''"Amazon"*''', color='3 7', ascii=r"""
${c1} `-/oydNNdyo:.`
`.:+shmMMMMMMMMMMMMMMmhs+:.`
-+hNNMMMMMMMMMMMMMMMMMMMMMMNNho-
.`` -/+shmNNMMMMMMNNmhs+/- ``.
dNmhs+:. `.:/oo/:.` .:+shmNd
dMMMMMMMNdhs+:.. ..:+shdNMMMMMMMd
dMMMMMMMMMMMMMMNds odNMMMMMMMMMMMMMMd
dMMMMMMMMMMMMMMMMh yMMMMMMMMMMMMMMMMd
dMMMMMMMMMMMMMMMMh yMMMMMMMMMMMMMMMMd
dMMMMMMMMMMMMMMMMh yMMMMMMMMMMMMMMMMd
dMMMMMMMMMMMMMMMMh yMMMMMMMMMMMMMMMMd
dMMMMMMMMMMMMMMMMh yMMMMMMMMMMMMMMMMd
dMMMMMMMMMMMMMMMMh yMMMMMMMMMMMMMMMMd
dMMMMMMMMMMMMMMMMh yMMMMMMMMMMMMMMMMd
dMMMMMMMMMMMMMMMMh yMMMMMMMMMMMMMMMMd
dMMMMMMMMMMMMMMMMh yMMMMMMMMMMMMMMMMd
.:+ydNMMMMMMMMMMMh yMMMMMMMMMMMNdy+:.
`.:+shNMMMMMh yMMMMMNhs+:``
`-+shy shs+:`
""")

25
tools/distros/amogos.py Normal file
View file

@ -0,0 +1,25 @@
from hyfetch.distro import AsciiArt
amogos = AsciiArt(match=r'''"AmogOS"*''', color='15 6', ascii=r"""
${c1} ___________
/ \
/ ${c2}______${c1} \
/ ${c2}/ \${c1} \
| ${c2}( )${c1} \
/ ${c2}\______/${c1} |
| |
/ \
| |
| |
/ |
| |
| _______ |
____/ / \ |
/ | | |
| / ____/ |
\_________/ / |
\ __/
\_______/
""")

34
tools/distros/anarchy.py Normal file
View file

@ -0,0 +1,34 @@
from hyfetch.distro import AsciiArt
anarchy = AsciiArt(match=r'''"Anarchy"*''', color='7 4', ascii=r"""
${c2}..${c1}
${c2}..${c1}
${c2}:..${c1}
${c2}:+++.${c1}
.:::++${c2}++++${c1}+::.
.:+######${c2}++++${c1}######+:.
.+#########${c2}+++++${c1}##########:.
.+##########${c2}+++++++${c1}##${c2}+${c1}#########+.
+###########${c2}+++++++++${c1}############:
+##########${c2}++++++${c1}#${c2}++++${c1}#${c2}+${c1}###########+
+###########${c2}+++++${c1}###${c2}++++${c1}#${c2}+${c1}###########+
:##########${c2}+${c1}#${c2}++++${c1}####${c2}++++${c1}#${c2}+${c1}############:
###########${c2}+++++${c1}#####${c2}+++++${c1}#${c2}+${c1}###${c2}++${c1}######+
.##########${c2}++++++${c1}#####${c2}++++++++++++${c1}#######.
.##########${c2}+++++++++++++++++++${c1}###########.
#####${c2}++++++++++++++${c1}###${c2}++++++++${c1}#########+
:###${c2}++++++++++${c1}#########${c2}+++++++${c1}#########:
+######${c2}+++++${c1}##########${c2}++++++++${c1}#######+
+####${c2}+++++${c1}###########${c2}+++++++++${c1}#####+
:##${c2}++++++${c1}############${c2}++++++++++${c1}##:
.${c2}++++++${c1}#############${c2}++++++++++${c1}+.
:${c2}++++${c1}###############${c2}+++++++${c1}::
.${c2}++. .:+${c1}##############${c2}+++++++${c1}..
${c2}.:.${c1} ..::++++++::..:${c2}++++${c1}+.
${c2}.${c1} ${c2}.:+++${c1}.
${c2}.:${c1}:
${c2}..${c1}
${c2}..${c1}
""")

24
tools/distros/android.py Normal file
View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
android = AsciiArt(match=r'''"Android"*''', color='2 7', ascii=r"""
${c1} -o o-
+hydNNNNdyh+
+mMMMMMMMMMMMMm+
`dMM${c2}m:${c1}NMMMMMMN${c2}:m${c1}MMd`
hMMMMMMMMMMMMMMMMMMh
.. yyyyyyyyyyyyyyyyyyyy ..
.mMMm`MMMMMMMMMMMMMMMMMMMM`mMMm.
:MMMM-MMMMMMMMMMMMMMMMMMMM-MMMM:
:MMMM-MMMMMMMMMMMMMMMMMMMM-MMMM:
:MMMM-MMMMMMMMMMMMMMMMMMMM-MMMM:
:MMMM-MMMMMMMMMMMMMMMMMMMM-MMMM:
-MMMM-MMMMMMMMMMMMMMMMMMMM-MMMM-
+yy+ MMMMMMMMMMMMMMMMMMMM +yy+
mMMMMMMMMMMMMMMMMMMm
`/++MMMMh++hMMMM++/`
MMMMo oMMMM
MMMMo oMMMM
oNMm- -mMNs
""")

View file

@ -0,0 +1,12 @@
from hyfetch.distro import AsciiArt
android_small = AsciiArt(match=r'''"android_small"*''', color='2 7', ascii=r"""
${c1} ;, ,;
';,.-----.,;'
,' ',
/ O O \\
| |
'-----------------'
""")

25
tools/distros/antergos.py Normal file
View file

@ -0,0 +1,25 @@
from hyfetch.distro import AsciiArt
antergos = AsciiArt(match=r'''"Antergos"*''', color='4 6', ascii=r"""
${c2} `.-/::/-``
.-/osssssssso/.
:osyysssssssyyys+-
`.+yyyysssssssssyyyyy+.
`/syyyyyssssssssssyyyyys-`
`/yhyyyyysss${c1}++${c2}ssosyyyyhhy/`
.ohhhyyyys${c1}o++/+o${c2}so${c1}+${c2}syy${c1}+${c2}shhhho.
.shhhhys${c1}oo++//+${c2}sss${c1}+++${c2}yyy${c1}+s${c2}hhhhs.
-yhhhhs${c1}+++++++o${c2}ssso${c1}+++${c2}yyy${c1}s+o${c2}hhddy:
-yddhhy${c1}o+++++o${c2}syyss${c1}++++${c2}yyy${c1}yooy${c2}hdddy-
.yddddhs${c1}o++o${c2}syyyyys${c1}+++++${c2}yyhh${c1}sos${c2}hddddy`
`odddddhyosyhyyyyyy${c1}++++++${c2}yhhhyosddddddo
.dmdddddhhhhhhhyyyo${c1}+++++${c2}shhhhhohddddmmh.
ddmmdddddhhhhhhhso${c1}++++++${c2}yhhhhhhdddddmmdy
dmmmdddddddhhhyso${c1}++++++${c2}shhhhhddddddmmmmh
-dmmmdddddddhhys${c1}o++++o${c2}shhhhdddddddmmmmd-
.smmmmddddddddhhhhhhhhhdddddddddmmmms.
`+ydmmmdddddddddddddddddddmmmmdy/.
`.:+ooyyddddddddddddyyso+:.`
""")

19
tools/distros/antix.py Normal file
View file

@ -0,0 +1,19 @@
from hyfetch.distro import AsciiArt
antix = AsciiArt(match=r'''"antiX"*''', color='1 7 3', ascii=r"""
${c1}
\
, - ~ ^ ~ - \ /
, ' \ ' , /
, \ '/
, \ / ,
,___, \/ ,
/ | _ _ _|_ o /\ ,
|, | / |/ | | | / \ ,
\,_/\_/ | |_/|_/|_/_/ \,
, / ,\
, / , ' \
' - , _ _ _ , '
""")

26
tools/distros/aosc_os.py Normal file
View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
aosc_os = AsciiArt(match=r'''"AOSC OS"*''', color='4 7 1', ascii=r"""
${c2} .:+syhhhhys+:.
.ohNMMMMMMMMMMMMMMNho.
`+mMMMMMMMMMMmdmNMMMMMMMMm+`
+NMMMMMMMMMMMM/ `./smMMMMMN+
.mMMMMMMMMMMMMMMo -yMMMMMm.
:NMMMMMMMMMMMMMMMs .hMMMMN:
.NMMMMhmMMMMMMMMMMm+/- oMMMMN.
dMMMMs ./ymMMMMMMMMMMNy. sMMMMd
-MMMMN` oMMMMMMMMMMMN: `NMMMM-
/MMMMh NMMMMMMMMMMMMm hMMMM/
/MMMMh NMMMMMMMMMMMMm hMMMM/
-MMMMN` :MMMMMMMMMMMMy. `NMMMM-
dMMMMs .yNMMMMMMMMMMMNy/. sMMMMd
.NMMMMo -/+sMMMMMMMMMMMmMMMMN.
:NMMMMh. .MMMMMMMMMMMMMMMN:
.mMMMMMy- NMMMMMMMMMMMMMm.
+NMMMMMms/.` mMMMMMMMMMMMN+
`+mMMMMMMMMNmddMMMMMMMMMMm+`
.ohNMMMMMMMMMMMMMMNho.
.:+syhhhhys+:.
""")

View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
aosc_os_retro = AsciiArt(match=r'''"AOSC OS/Retro"*''', color='4 7 1 3', ascii=r"""
${c2} .........
...................
.....................${c1}################${c2}
.............. ....${c1}################${c2}
.............. ...${c1}################${c2}
............. ..${c1}****************${c2}
............ . .${c1}****************${c2}
........... ... ${c1}................${c2}
.......... ..... ${c1}...............${c2}
......... ....... ...
.${c3}...... ${c2}.
${c3}..... .....${c2}.... ${c4}...........
${c3}.... ......${c2}. ${c4}...........
${c3}... ....... ${c4}...........
${c3}................ ${c4}***********
${c3}................ ${c4}###########
${c3}****************
${c3}################
""")

View file

@ -0,0 +1,15 @@
from hyfetch.distro import AsciiArt
aoscosretro_small = AsciiArt(match=r'''"aoscosretro_small"''', color='4 7 1 3', ascii=r"""
${c2} _____ ${c1}_____${c2}
-' '-${c1}| |${c2}
/ ___ ${c1}| |${c2}
| / _ \\${c1}|_____|${c2}
' / /_\\ \\
\\ / _____ \\${c4}___
${c3}|${c2}/_/ ${c3}| ${c4}| |
${c3}| | ${c4}|___|
${c3}|_____|
""")

View file

@ -0,0 +1,10 @@
from hyfetch.distro import AsciiArt
aperio_gnu_linux = AsciiArt(match=r'''"Aperio GNU/Linux"*''', color='255', ascii=r"""
${c2}
_.._ _ ._.. _
(_][_)(/,[ |(_)
| GNU/Linux
""")

24
tools/distros/apricity.py Normal file
View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
apricity = AsciiArt(match=r'''"Apricity"*''', color='4 7 1', ascii=r"""
${c2} ./o-
``...`` `:. -/:
`-+ymNMMMMMNmho-` :sdNNm/
`+dMMMMMMMMMMMMMMMmo` sh:.:::-
/mMMMMMMMMMMMMMMMMMMMm/`sNd/
oMMMMMMMMMMMMMMMMMMMMMMMs -`
:MMMMMMMMMMMMMMMMMMMMMMMMM/
NMMMMMMMMMMMMMMMMMMMMMMMMMd
MMMMMMMmdmMMMMMMMMMMMMMMMMd
MMMMMMy` .mMMMMMMMMMMMmho:`
MMMMMMNo/sMMMMMMMNdy+-.`-/
MMMMMMMMMMMMNdy+:.`.:ohmm:
MMMMMMMmhs+-.`.:+ymNMMMy.
MMMMMM/`.-/ohmNMMMMMMy-
MMMMMMNmNNMMMMMMMMmo.
MMMMMMMMMMMMMMMms:`
MMMMMMMMMMNds/.
dhhyys+/-`
""")

25
tools/distros/arch.py Normal file
View file

@ -0,0 +1,25 @@
from hyfetch.distro import AsciiArt
arch = AsciiArt(match=r'''"Arch"*''', color='6 6 7 1', ascii=r"""
${c1} -`
.o+`
`ooo/
`+oooo:
`+oooooo:
-+oooooo+:
`/:-:++oooo+:
`/++++/+++++++:
`/++++++++++++++:
`/+++o${c2}oooooooo${c1}oooo/`
${c2} ${c1}./${c2}ooosssso++osssssso${c1}+`
${c2} .oossssso-````/ossssss+`
-osssssso. :ssssssso.
:osssssss/ osssso+++.
/ossssssss/ +ssssooo/-
`/ossssso+/:- -:/+osssso+-
`+sso+:-` `.-/+oso:
`++:. `-/+/
.` `/
""")

22
tools/distros/arch_old.py Normal file
View file

@ -0,0 +1,22 @@
from hyfetch.distro import AsciiArt
arch_old = AsciiArt(match=r'''"arch_old"''', color='6 7 1', ascii=r"""
${c1} __
_=(SDGJT=_
_GTDJHGGFCVS)
,GTDJGGDTDFBGX0
${c1} JDJDIJHRORVFSBSVL${c2}-=+=,_
${c1} IJFDUFHJNXIXCDXDSV,${c2} "DEBL
${c1} [LKDSDJTDU=OUSCSBFLD.${c2} '?ZWX,
${c1} ,LMDSDSWH' `DCBOSI${c2} DRDS],
${c1} SDDFDFH' !YEWD,${c2} )HDROD
${c1} !KMDOCG &GSU|${c2}\_GFHRGO\'
${c1} HKLSGP'${c2} __${c1}\TKM0${c2}\GHRBV)'
${c1}JSNRVW'${c2} __+MNAEC${c1}\IOI,${c2}\BN'
${c1}HELK['${c2} __,=OFFXCBGHC${c1}\FD)
${c1}?KGHE ${c2}\_-#DASDFLSV='${c1} 'EF
'EHTI !H
`0F' '!
""")

View file

@ -0,0 +1,13 @@
from hyfetch.distro import AsciiArt
arch_small = AsciiArt(match=r'''"arch_small"''', color='6 7 1', ascii=r"""
${c1} /\\
/ \\
/\\ \\
${c2} / \\
/ ,, \\
/ | | -\\
/_-'' ''-_\\
""")

25
tools/distros/archbox.py Normal file
View file

@ -0,0 +1,25 @@
from hyfetch.distro import AsciiArt
archbox = AsciiArt(match=r'''"ArchBox"*''', color='2 7 1', ascii=r"""
${c1} ...:+oh/:::..
..-/oshhhhhh` `::::-.
.:/ohhhhhhhhhhhh` `-::::.
.+shhhhhhhhhhhhhhhhh` `.::-.
/`-:+shhhhhhhhhhhhhh` .-/+shh
/ .:/ohhhhhhhhh` .:/ohhhhhhhh
/ `-:+shhh` ..:+shhhhhhhhhhhh
/ .:ohhhhhhhhhhhhhhhhhhh
/ `hhhhhhhhhhhhhhhhhhhh
/ `hhhhhhhhhhhhhhhhhhhh
/ `hhhhhhhhhhhhhhhhhhhh
/ `hhhhhhhhhhhhhhhhhhhh
/ .+o+ `hhhhhhhhhhhhhhhhhhhh
/ -hhhhh `hhhhhhhhhhhhhhhhhhhh
/ ohhhhho `hhhhhhhhhhhhhhhhhhhh
/:::+`hhhhoos` `hhhhhhhhhhhhhhhhhs+`
`--/:` /: `hhhhhhhhhhhho/-
-/:. `hhhhhhs+:-`
::::/ho/-`
""")

View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
archcraft = AsciiArt(match=r'''"Archcraft"*''', color='6 1 2 3 4 5', ascii=r"""
${c1}${c1}${c1}
${c2}${c1}${c2}
${c3}${c1}${c3}
${c4}${c1}${c4}
${c5}${c1}${c5}
${c6}${c1}${c6}
${c1}${c1}${c1}
${c2}${c1}${c2}
${c3}${c1}${c3}
${c4}${c1}${c4}
${c5}${c1}${c5}
${c6}${c1}${c6}${c1}${c6}
${c1}${c1}${c1}${c1}${c1}
${c2}${c1}${c2}${c1}${c1}${c2}
${c3}${c1}${c3}${c1}${c3}${c1}${c3}
${c4}${c1}${c4}${c1}${c4}${c1}${c4}
${c5}${c1}${c5}${c1}${c5}
${c6}${c1}${c6}${c1}${c6}
${c1}${c1}${c1}${c1}${c1}
${c1}${c2}${c1}
""")

27
tools/distros/archlabs.py Normal file
View file

@ -0,0 +1,27 @@
from hyfetch.distro import AsciiArt
archlabs = AsciiArt(match=r'''"ARCHlabs"*''', color='6 6 7 1', ascii=r"""
${c1} 'c'
'kKk,
.dKKKx.
.oKXKXKd.
.l0XXXXKKo.
c0KXXXXKX0l.
:0XKKOxxOKX0l.
:OXKOc. .c0XX0l.
:OK0o. ${c4}...${c1}'dKKX0l.
:OX0c ${c4};xOx'${c1}'dKXX0l.
:0KKo.${c4}.o0XXKd'.${c1}lKXX0l.
c0XKd.${c4}.oKXXXXKd..${c1}oKKX0l.
.c0XKk;${c4}.l0K0OO0XKd..${c1}oKXXKo.
.l0XXXk:${c4},dKx,.'l0XKo.${c1}.kXXXKo.
.o0XXXX0d,${c4}:x; .oKKx'${c1}.dXKXXKd.
.oKXXXXKK0c.${c4};. :00c'${c1}cOXXXXXKd.
.dKXXXXXXXXk,${c4}. cKx'${c1}'xKXXXXXXKx'
'xKXXXXK0kdl:. ${c4}.ok; ${c1}.cdk0KKXXXKx'
'xKK0koc,.. ${c4}'c, ${c1} ..,cok0KKk,
,xko:'. ${c4}.. ${c1} .':okx;
.,'. .',.
""")

View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
archmerge = AsciiArt(match=r'''"ArchMerge"*''', color='6 6 7 1', ascii=r"""
${c1} y:
sMN-
+MMMm`
/MMMMMd`
:NMMMMMMy
-NMMMMMMMMs
.NMMMMMMMMMM+
.mMMMMMMMMMMMM+
oNMMMMMMMMMMMMM+
`+:-+NMMMMMMMMMMMM+
.sNMNhNMMMMMMMMMMMM/
`hho/sNMMMMMMMMMMMMMMM/
`.`omMMmMMMMMMMMMMMMMMMM+
.mMNdshMMMMd+::oNMMMMMMMMMo
.mMMMMMMMMM+ `yMMMMMMMMMs
.NMMMMMMMMM/ yMMMMMMMMMy
-NMMMMMMMMMh `mNMMMMMMMMd`
/NMMMNds+:.` `-/oymMMMm.
+Mmy/. `:smN:
/+. -o.
""")

View file

@ -0,0 +1,23 @@
from hyfetch.distro import AsciiArt
archstrike = AsciiArt(match=r'''"ArchStrike"*''', color='8 6', ascii=r"""
${c1} *
**.
****
******
*******
** *******
**** *******
${c1}****${c2}_____${c1}***${c2}/${c1}*
***${c2}/${c1}*******${c2}//${c1}***
**${c2}/${c1}********${c2}///${c1}*${c2}/${c1}**
**${c2}/${c1}*******${c2}////${c1}***${c2}/${c1}**
**${c2}/${c1}****${c2}//////.,${c1}****${c2}/${c1}**
***${c2}/${c1}*****${c2}/////////${c1}**${c2}/${c1}***
****${c2}/${c1}**** ${c2}/////${c1}***${c2}/${c1}****
******${c2}/${c1}*** ${c2}//// ${c1}**${c2}/${c1}******
********${c2}/${c1}* ${c2}/// ${c1}*${c2}/${c1}********
,****** ${c2}// ______ / ${c1}******,
""")

View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
arcolinux = AsciiArt(match=r'''"ArcoLinux"*''', color='7 4', ascii=r"""
${c2} /-
ooo:
yoooo/
yooooooo
yooooooooo
yooooooooooo
.yooooooooooooo
.oooooooooooooooo
.oooooooarcoooooooo
.ooooooooo-oooooooooo
.ooooooooo- oooooooooo
:ooooooooo. :ooooooooo
:ooooooooo. :ooooooooo
:oooarcooo .oooarcooo
:ooooooooy .ooooooooo
:ooooooooo ${c1}/ooooooooooooooooooo${c2}
:ooooooooo ${c1}.-ooooooooooooooooo.${c2}
ooooooooo- ${c1}-ooooooooooooo.${c2}
ooooooooo- ${c1}.-oooooooooo.${c2}
ooooooooo. ${c1}-ooooooooo${c2}
""")

View file

@ -0,0 +1,17 @@
from hyfetch.distro import AsciiArt
arcolinux_small = AsciiArt(match=r'''"arcolinux_small"*''', color='7 4', ascii=r"""
${c2} A
ooo
ooooo
ooooooo
ooooooooo
ooooo ooooo
ooooo ooooo
ooooo ooooo
ooooo ${c1}<oooooooo>${c2}
ooooo ${c1}<oooooo>${c2}
ooooo ${c1}<oooo>${c2}
""")

26
tools/distros/artix.py Normal file
View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
artix = AsciiArt(match=r'''"Artix"*''', color='6 6 7 1', ascii=r"""
${c1} '
'o'
'ooo'
'ooxoo'
'ooxxxoo'
'oookkxxoo'
'oiioxkkxxoo'
':;:iiiioxxxoo'
`'.;::ioxxoo'
'-. `':;jiooo'
'oooio-.. `'i:io'
'ooooxxxxoio:,. `'-;'
'ooooxxxxxkkxoooIi:-. `'
'ooooxxxxxkkkkxoiiiiiji'
'ooooxxxxxkxxoiiii:'` .i'
'ooooxxxxxoi:::'` .;ioxo'
'ooooxooi::'` .:iiixkxxo'
'ooooi:'` `'';ioxxo'
'i:'` '':io'
'` `'
""")

View file

@ -0,0 +1,19 @@
from hyfetch.distro import AsciiArt
artix_small = AsciiArt(match=r'''"artix_small"*''', color='6 6 7 1', ascii=r"""
${c1} '
'A'
'ooo'
'ookxo'
`ookxxo'
'. `ooko'
'ooo`. `oo'
'ooxxxoo`. `'
'ookxxxkooo.` .
'ookxxkoo'` .'oo'
'ooxoo'` .:ooxxo'
'io'` `'oo'
'` `'
""")

21
tools/distros/arya.py Normal file
View file

@ -0,0 +1,21 @@
from hyfetch.distro import AsciiArt
arya = AsciiArt(match=r'''"Arya"*''', color='2 1', ascii=r"""
${c1} `oyyy/${c2}-yyyyyy+
${c1} -syyyy/${c2}-yyyyyy+
${c1} .syyyyy/${c2}-yyyyyy+
${c1} :yyyyyy/${c2}-yyyyyy+
${c1} `/ :yyyyyy/${c2}-yyyyyy+
${c1} .+s :yyyyyy/${c2}-yyyyyy+
${c1} .oys :yyyyyy/${c2}-yyyyyy+
${c1} -oyys :yyyyyy/${c2}-yyyyyy+
${c1} :syyys :yyyyyy/${c2}-yyyyyy+
${c1} /syyyys :yyyyyy/${c2}-yyyyyy+
${c1} +yyyyyys :yyyyyy/${c2}-yyyyyy+
${c1} .oyyyyyyo. :yyyyyy/${c2}-yyyyyy+ ---------
${c1} .syyyyyy+` :yyyyyy/${c2}-yyyyy+-+syyyyyyyy
${c1} -syyyyyy/ :yyyyyy/${c2}-yyys:.syyyyyyyyyy
${c1}:syyyyyy/ :yyyyyy/${c2}-yyo.:syyyyyyyyyyy
""")

24
tools/distros/asahi.py Normal file
View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
asahi = AsciiArt(match=r'''"Asahi"*''', color='3 2 1 8 7 6 4', ascii=r"""
${c1} ## ${c2}**
${c1}*####${c2}****.
${c1}###${c2},
${c3}...,${c1}/#${c3},,,..
${c3}/*,,,,,,,,${c1}*${c3},........${c4},,
${c3},((((((//*,,,,,,,,${c4},......
${c3}((((((((((((((${c5}%..${c4}..........
${c3},(((((((((((((((${c5}@@(${c4}............
${c3}(((((((((((((((((${c5}@@@@/${c4}............
${c3},((((((((((((((((((${c5}@@@@@&*${c4}...........
${c3}((((((((((((((((((((${c5}@@@@@@@&${c4},...........
${c3}(((((((((((((((((((((${c5}@@@${c6}&%&${c5}@@@%${c4},..........
${c3}/(((((((((((((((((((${c5}@@@${c6}&%%&${c5}@@@@(${c4}........
${c3},((((((((((((((((${c5}@@@${c6}&&${c5}@@&/&@@@/${c4}..
${c3}/((((((((((((${c5}@@@@@@/${c4}.../&&
${c3}.(((((((((${c5}@@@@(${c4}....
${c3}/(((((${c5}@@#${c4}...
${c3}.((${c4}&,
""")

View file

@ -0,0 +1,23 @@
from hyfetch.distro import AsciiArt
asteroidos = AsciiArt(match=r'''"AsteroidOS"*''', color='160 208 202 214', ascii=r"""
${c1} ***
${c1} *****
${c1} **********
${c1} ***************
${c1} *///****////****////.
${c2} (/////// /////// ///////(
${c2} /(((((//* //, //((((((.
${c2} ((((((((((( ((( ((((((((
${c2} *((((((((((((((((((((((( ((((((((
${c3} (((((#(((((((#((((( ((#(((((
${c3} (#(#(#####(#(#, ####(#(#
${c3} ######### ########
${c3} /######## ########
${c4} #######%#######
${c4} (#%%%%%%%#
${c4} %%%%%
${c4} %%%
""")

23
tools/distros/bedrock.py Normal file
View file

@ -0,0 +1,23 @@
from hyfetch.distro import AsciiArt
bedrock = AsciiArt(match=r'''"Bedrock"*''', color='8 7', ascii=r"""
${c1}--------------------------------------
--------------------------------------
--------------------------------------
---${c2}\\\\\\\\\\\\\\\\\\\\\\\\${c1}-----------------------
----${c2}\\\\\\ \\\\\\${c1}----------------------
-----${c2}\\\\\\ \\\\\\${c1}---------------------
------${c2}\\\\\\ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\${c1}------
-------${c2}\\\\\\ \\\\\\${c1}-----
--------${c2}\\\\\\ \\\\\\${c1}----
---------${c2}\\\\\\ ______ \\\\\\${c1}---
----------${c2}\\\\\\ ///${c1}---
-----------${c2}\\\\\\ ///${c1}----
------------${c2}\\\\\\ ///${c1}-----
-------------${c2}\\\\\\////////////////${c1}------
--------------------------------------
--------------------------------------
--------------------------------------
""")

25
tools/distros/biglinux.py Normal file
View file

@ -0,0 +1,25 @@
from hyfetch.distro import AsciiArt
biglinux = AsciiArt(match=r'''"BigLinux"*''', color='6 11 4', ascii=r"""
${c1} ...
:OWMMMNd.
:NMMMMMMMMWc
okkl. kMMMMMW0xdOWMl
: xMMMMMW. kMMMMNc lW.
:x NMMMMMO ,MMMM0. 'l
Xx "lkk" kMMMX .okx,
${c2}.MX .cc;. .xXKx. KMMM: .OMMMMMl
:MM' 'KMMMMWK: 0MMMMk xMMM. lWMMMMMMM'
cMMN:;xMMMMk::MMO oMMMMX .XMM. .KMMMWOOMMMd
'MMMMMMMMN, NMMx OMMMMl .kM0OMMMMk. ;MMd
xMMMMMMd .MMMW :NMMMd .ckKKx' KMc
dWMNd. oMMMN lkNMX, oM.
;. ;MMMMx "MM:. cO
${c3} .X. oMMMMW. l.
dMk:..;xWMMMMW,
kMMMMMMMMMMX.
:XMMMMMMK:
':MM:" Made in Brazil
""")

23
tools/distros/bitrig.py Normal file
View file

@ -0,0 +1,23 @@
from hyfetch.distro import AsciiArt
bitrig = AsciiArt(match=r'''"Bitrig"*''', color='2 7', ascii=r"""
${c1} `hMMMMN+
-MMo-dMd`
oMN- oMN`
yMd /NM:
.mMmyyhMMs
:NMMMhsmMh
+MNhNNoyMm-
hMd.-hMNMN:
mMmsssmMMMo
.MMdyyhNMMMd
oMN.`/dMddMN`
yMm/hNm+./MM/
.dMMMmo.``.NMo
:NMMMNmmmmmMMh
/MN/-------oNN:
hMd. .dMh
sm/ /ms
""")

View file

@ -0,0 +1,27 @@
from hyfetch.distro import AsciiArt
blackarch = AsciiArt(match=r'''"BlackArch"*''', color='1 1 0 1', ascii=r"""
${c3} 00
11
====${c1}
.${c3}//${c1}
`o${c3}//${c1}:
`+o${c3}//${c1}o:
`+oo${c3}//${c1}oo:
-+oo${c3}//${c1}oo+:
`/:-:+${c3}//${c1}ooo+:
`/+++++${c3}//${c1}+++++:
`/++++++${c3}//${c1}++++++:
`/+++o${c2}ooo${c3}//${c2}ooo${c1}oooo/`
${c2} ${c1}./${c2}ooosssso${c3}//${c2}osssssso${c1}+`
${c2} .oossssso-`${c3}//${c1}`/ossssss+`
-osssssso. ${c3}//${c1} :ssssssso.
:osssssss/ ${c3}//${c1} osssso+++.
/ossssssss/ ${c3}//${c1} +ssssooo/-
`/ossssso+/:- ${c3}//${c1} -:/+osssso+-
`+sso+:-` ${c3}//${c1} `.-/+oso:
`++:. ${c3}//${c1} `-/+/
.` ${c3}/${c1} `/
""")

View file

@ -0,0 +1,29 @@
from hyfetch.distro import AsciiArt
blackpanther = AsciiArt(match=r'''"blackPanther"* | 'blackpanther'*''', color='1 11 12', ascii=r"""
${c3} ........
.,»g,.
,j;»j,
.»»;:`${c2}``>${c1} ${c3} ,
.j»»»;:```` ,
;»»»»;```` φ Ñ>.
.j»»¿``/U.
.jÜÑ@H.
«ÑÑM"▀███████████████▓╫░
:]ÑÑÑÑ»»Ñ~
»ÑÑ»»
`jÑ»»U`
`/»»»;w`
;»»;:`Ü >`
`];:````µp ,M`
"╠╣██▌░░░░░░░»██▌;```` ╙▀██████████████M █▀"
"╟╣█░░░░░░░░»███⌂``` ▐▀████████▀░ █▌░`
"╩█▄░░░░░░»»▀███ `` └└` ,█▀"`
`»»»»@ .Ü`
`@»»»;`¿ ,Ñ"`
`"╨▀█▄▄▄░`▐█████▄, ,▄▄▀▀░`
`"╙╩▀▀▀▀████████▓▌▌▌▀▀▀╨"``
``""""``
""")

23
tools/distros/blag.py Normal file
View file

@ -0,0 +1,23 @@
from hyfetch.distro import AsciiArt
blag = AsciiArt(match=r'''"BLAG"*''', color='5 7', ascii=r"""
${c1} d
,MK:
xMMMX:
.NMMMMMX;
lMMMMMMMM0clodkO0KXWW:
KMMMMMMMMMMMMMMMMMMX'
.;d0NMMMMMMMMMMMMMMMMMMK.
.;dONMMMMMMMMMMMMMMMMMMMMMMx
'dKMMMMMMMMMMMMMMMMMMMMMMMMl
.:xKWMMMMMMMMMMMMMMMMMMM0.
.:xNMMMMMMMMMMMMMMMMMK.
lMMMMMMMMMMMMMMMMMMK.
,MMMMMMMMWkOXWMMMMMM0
.NMMMMMNd. `':ldko
OMMMK:
oWk,
;:
""")

23
tools/distros/blankon.py Normal file
View file

@ -0,0 +1,23 @@
from hyfetch.distro import AsciiArt
blankon = AsciiArt(match=r'''"BlankOn"*''', color='1 7 3', ascii=r"""
${c2} `./ohdNMMMMNmho+.` ${c1} .+oo:`
${c2} -smMMMMMMMMMMMMMMMMmy-` ${c1}`yyyyy+
${c2} `:dMMMMMMMMMMMMMMMMMMMMMMd/` ${c1}`yyyyys
${c2} .hMMMMMMMNmhso/++symNMMMMMMMh- ${c1}`yyyyys
${c2} -mMMMMMMms-` -omMMMMMMN-${c1}.yyyyys
${c2}.mMMMMMMy. .yMMMMMMm:${c1}yyyyys
${c2}sMMMMMMy `sMMMMMMh${c1}yyyyys
${c2}NMMMMMN: .NMMMMMN${c1}yyyyys
${c2}MMMMMMm. NMMMMMN${c1}yyyyys
${c2}hMMMMMM+ /MMMMMMN${c1}yyyyys
${c2}:NMMMMMN: :mMMMMMM+${c1}yyyyys
${c2} oMMMMMMNs- .sNMMMMMMs.${c1}yyyyys
${c2} +MMMMMMMNho:.` `.:ohNMMMMMMNo ${c1}`yyyyys
${c2} -hMMMMMMMMNNNmmNNNMMMMMMMMh- ${c1}`yyyyys
${c2} :yNMMMMMMMMMMMMMMMMMMNy:` ${c1}`yyyyys
${c2} .:sdNMMMMMMMMMMNds/. ${c1}`yyyyyo
${c2} `.:/++++/:.` ${c1}:oys+.
""")

View file

@ -0,0 +1,25 @@
from hyfetch.distro import AsciiArt
bluelight = AsciiArt(match=r'''"BlueLight"*''', color='7 4', ascii=r"""
${c1} oMMNMMMMMMMMMMMMMMMMMMMMMM
oMMMMMMMMMMMMMMMMMMMMMMMMM
oMMMMMMMMMMMMMMMMMMMMMMMMM
oMMMMMMMMMMMMMMMMMMMMMMMMM
-+++++++++++++++++++++++mM${c2}
```````````````````````..${c1}dM${c2}
```````````````````````....${c1}dM${c2}
```````````````````````......${c1}dM${c2}
```````````````````````........${c1}dM${c2}
```````````````````````..........${c1}dM${c2}
```````````````````````............${c1}dM${c2}
.::::::::::::::::::::::-..............${c1}dM${c2}
`-+yyyyyyyyyyyyyyyyyyyo............${c1}+mMM${c2}
-+yyyyyyyyyyyyyyyyo..........${c1}+mMMMM${c2}
./syyyyyyyyyyyyo........${c1}+mMMMMMM${c2}
./oyyyyyyyyyo......${c1}+mMMMMMMMM${c2}
omdyyyyyyo....${c1}+mMMMMMMMMMM${c2}
${c1}oMMM${c2}mdhyyo..${c1}+mMMMMMMMMMMMM
oNNNNNNm${c2}dso${c1}mMMMMMMMMMMMMMM
""")

24
tools/distros/bodhi.py Normal file
View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
bodhi = AsciiArt(match=r'''"Bodhi"*''', color='7 11 2', ascii=r"""
${c1}| ${c2},,mmKKKKKKKKWm,,
${c1}' ${c2},aKKP${c1}LL**********|L*${c2}TKp,
${c1}t ${c2}aKP${c1}L**``` ```**L${c2}*Kp
IX${c1}EL${c3}L,wwww, ${c1}``*||${c2}Kp
,#P${c1}L|${c3}KKKpPP@IPPTKmw, ${c1}`*||${c2}K
,K${c1}LL*${c3}{KKKKKKPPb$KPhpKKPKp ${c1}`||${c2}K
#${c1}PL ${c3}!KKKKKKPhKPPP$KKEhKKKKp ${c1}`||${c2}K
!H${c1}L* ${c3}1KKKKKKKphKbPKKKKKK$KKp ${c1}`|I${c2}W
$${c1}bL ${c3}KKKKKKKKBQKhKbKKKKKKKK ${c1}|I${c2}N
$${c1}bL ${c3}!KKKKKKKKKKNKKKKKKKPP` ${c1}|I${c2}b
TH${c1}L* ${c3}TKKKKKK##KKKN@KKKK^ ${c1}|I${c2}M
K@${c1}L ${c3}*KKKKKKKKKKKEKE5 ${c1}||${c2}K
`NL${c1}L ${c3}`KKKKKKKKKK"```|L ${c1}||${c2}#P
`K@${c1}LL ${c3}`"**"` ${c1}'. :||${c2}#P
Yp${c1}LL ${c1}' |L${c2}$M`
`Tp${c1}pLL, ,|||${c2}p'L
"Kpp${c1}LL++,., ,,|||$${c2}#K* ${c1}'.
${c2}`"MKWpppppppp#KM"` ${c1}`h,
""")

22
tools/distros/bonsai.py Normal file
View file

@ -0,0 +1,22 @@
from hyfetch.distro import AsciiArt
bonsai = AsciiArt(match=r'''"bonsai"*''', color='6 2 3', ascii=r"""
${c2} ,####,
${c2}#######, ${c2},#####,
${c2}#####',# ${c2}'######
${c2}''###'${c3}';,,,'${c2}###'
${c3} ,; ''''
${c3} ;;; ${c2},#####,
${c3} ;;;' ,,;${c2};;###
${c3} ';;;;''${c2}'####'
${c3} ;;;
${c3} ,.;;';'',,,
${c3} ' '
${c1} #
# O
##, ,##,',##, ,## ,#, ,
# # # # #''# #,, # # #
'#' '##' # # ,,# '##;, #
""")

25
tools/distros/bsd.py Normal file
View file

@ -0,0 +1,25 @@
from hyfetch.distro import AsciiArt
bsd = AsciiArt(match=r'''*"BSD"''', color='1 7 4 3 6', ascii=r"""
${c1} , ,
/( )`
\ \___ / |
/- _ `-/ '
(${c2}/\/ \ ${c1}\ /\
${c2}/ / | ` ${c1}\
${c3}O O ${c2}) ${c1}/ |
${c2}`-^--'${c1}`< '
(_.) _ ) /
`.___/` /
`-----' /
${c4}<----. __ / __ \
${c4}<----|====${c1}O)))${c4}==${c1}) \) /${c4}====|
<----' ${c1}`--' `.__,' \
| |
\ / /\
${c5}______${c1}( (_ / \______/
${c5},' ,-----' |
`--{__________)
""")

View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
bunsenlabs = AsciiArt(match=r'''"BunsenLabs"*''', color='fg 7', ascii=r"""
${c1} `++
-yMMs
`yMMMMN`
-NMMMMMMm.
:MMMMMMMMMN-
.NMMMMMMMMMMM/
yMMMMMMMMMMMMM/
`MMMMMMNMMMMMMMN.
-MMMMN+ /mMMMMMMy
-MMMm` `dMMMMMM
`MMN. .NMMMMM.
hMy yMMMMM`
-Mo +MMMMN
/o +MMMMs
+MMMN`
hMMM:
`NMM/
+MN:
mh.
-/
""")

28
tools/distros/cachy_os.py Normal file
View file

@ -0,0 +1,28 @@
from hyfetch.distro import AsciiArt
cachy_os = AsciiArt(match=r'''"Cachy OS"*''', color='2 8 6', ascii=r"""
${c3} ${c2}.${c3}-------------------------:
${c3} .${c1}+=${c3}========================.
${c3} :${c1}++${c3}===${c1}++===${c3}===============- :${c1}++${c3}-
${c3} :${c1}*++${c3}====${c1}+++++==${c3}===========- .==:
${c3} -${c1}*+++${c3}=====${c1}+***++=${c3}=========:
${c3} =${c1}*++++=${c3}=======------------:
${c3} =${c1}*+++++=${c3}====- ${c2}...${c3}
${c3} .${c1}+*+++++${c3}=-===: .${c1}=+++=${c3}:
${c3} :${c1}++++${c3}=====-==: -***${c1}**${c3}+
${c3} :${c1}++=${c3}=======-=. .=+**+${c2}.${c3}
${c3}.${c1}+${c3}==========-. ${c2}.${c3}
${c3} :${c1}+++++++${c3}====- ${c2}.${c3}--==-${c2}.${c3}
${c3} :${c1}++${c3}==========. ${c2}:${c1}+++++++${c3}${c2}:
${c3} .-===========. =*****+*+
${c3} .-===========: .+*****+:
${c3} -=======${c1}++++${c3}:::::::::::::::::::::::::-: ${c2}.${c3}---:
${c3} :======${c1}++++${c3}====${c1}+++******************=.
${c3} :=====${c1}+++${c3}==========${c1}++++++++++++++*-
${c3} .====${c1}++${c3}==============${c1}++++++++++*-
${c3} .===${c1}+${c3}==================${c1}+++++++:
${c3} .-=======================${c1}+++:
${c3} ${c2}..........................
""")

View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
calculate = AsciiArt(match=r'''"Calculate"*''', color='7 3', ascii=r"""
${c1} ......
,,+++++++,.
.,,,....,,,${c2}+**+,,.${c1}
............,${c2}++++,,,${c1}
...............
......,,,........
.....+*#####+,,,*+.
.....,*###############,..,,,,,,..
......,*#################*..,,,,,..,,,..
.,,....*####################+***+,,,,...,++,
.,,..,..*#####################*,
,+,.+*..*#######################.
,+,,+*+..,########################*
.,++++++. ..+##**###################+
..... ..+##***#################*.
.,.*#*****##############*.
..,,*********#####****+.
${c2}.,++*****+++${c1}*****************${c2}+++++,.${c1}
${c2},++++++**+++++${c1}***********${c2}+++++++++,${c1}
${c2}.,,,,++++,.. .,,,,,.....,+++,.,,${c1}
""")

View file

@ -0,0 +1,32 @@
from hyfetch.distro import AsciiArt
calinixos = AsciiArt(match=r'''"CalinixOS"''', color='4 5 4 4 4 4', ascii=r"""
${c2}
""")

View file

@ -0,0 +1,22 @@
from hyfetch.distro import AsciiArt
calinixos_small = AsciiArt(match=r'''"CalinixOS_small"*''', color='4 5 4 4 4 4', ascii=r"""
${c2}
""")

24
tools/distros/carbs.py Normal file
View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
carbs = AsciiArt(match=r'''"Carbs"*''', color='4 5 4 4 4 4', ascii=r"""
${c2} ..........
..,;:ccccccc:;'..
..,clllc:;;;;;:cllc,.
.,cllc,... ..';;'.
.;lol;.. ..
.,lol;.
.coo:.
.'lol,.
.,lol,.
.,lol,.
'col;.
.:ooc'.
.'col:.
.'cllc'.. .''.
..:lolc,'.......',cll,.
..;cllllccccclllc;'.
...',;;;;;;,,...
.....
""")

View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
cbl_mariner = AsciiArt(match=r'''"CBL-Mariner"*''', color='6', ascii=r"""
${c1} .
:- .
:==. .=:
:===: -==:
:-===: .====:
:-====- -=====:
-====== :=======:
-======. .=========:
-======: -==========.
-======- -===========.
:======- :===========.
:=======. .-==========.
:=======: -==========.
:=======- :==========.
:=======- .-========-
:--------. :========-
..:::--=========-
..::---================-=-
""")

26
tools/distros/celos.py Normal file
View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
celos = AsciiArt(match=r'''"CelOS"*''', color='4 6 0 5', ascii=r"""
${c4} .,cmmmmmmmmmmmc,.
.,cmMMMMMMMMMMMMMMMMMMMMmc.
.cMMMMMMMMMMMMMMMMMMMMMMMMMMMmc.
.cMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMc.
,:MMM ${c3}####################################${c4}
cMMMMMMmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmc.
.MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM.
.MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMc
"******************************MMMMMMMMMMMMMc:
${c3}#################################### ${c4}MMMMMMMMMMMMMc
"MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM:
"MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM"
'MMMMMMMMM*******************************:
\"MMMMMM ${c3}#####################################
${c4}`:MMMMMMmmmmmmmmmmmmmmmmmmmmmmmmmmmmm;
`"MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM"
`":MMMMMMMMMMMMMMMMMMMMMMMMM;'
`":MMMMMMMMMMMMMMMMMMM:"
"************"
""")

19
tools/distros/center.py Normal file
View file

@ -0,0 +1,19 @@
from hyfetch.distro import AsciiArt
center = AsciiArt(match=r'''"Center"*''', color='7 7', ascii=r"""
${c2} .
o,
. d, .
';' ..d;.. .cl'
.:; 'oldO,.oo.
..,:,xKXxoo;'.
,;;;;;ldxkONMMMXxkxc;;;;;.
.....':oddXWMNOxlcl:......
.:dlxk0c;:. .
:d:.,xcld,.,:.
;l, .l; ';'
.o;
l,
""")

25
tools/distros/centos.py Normal file
View file

@ -0,0 +1,25 @@
from hyfetch.distro import AsciiArt
centos = AsciiArt(match=r'''"CentOS"*''', color='3 2 4 5 7', ascii=r"""
${c1} ..
.PLTJ.
<><><><>
${c2}KKSSV' 4KKK ${c1}LJ${c4} KKKL.'VSSKK
${c2}KKV' 4KKKKK ${c1}LJ${c4} KKKKAL 'VKK
${c2}V' ' 'VKKKK ${c1}LJ${c4} KKKKV' ' 'V
${c2}.4MA.' 'VKK ${c1}LJ${c4} KKV' '.4Mb.
${c4} . ${c2}KKKKKA.' 'V ${c1}LJ${c4} V' '.4KKKKK ${c3}.
${c4} .4D ${c2}KKKKKKKA.'' ${c1}LJ${c4} ''.4KKKKKKK ${c3}FA.
${c4}<QDD ++++++++++++ ${c3}++++++++++++ GFD>
${c4} 'VD ${c3}KKKKKKKK'.. ${c2}LJ ${c1}..'KKKKKKKK ${c3}FV
${c4} ' ${c3}VKKKKK'. .4 ${c2}LJ ${c1}K. .'KKKKKV ${c3}'
${c3} 'VK'. .4KK ${c2}LJ ${c1}KKA. .'KV'
${c3}A. . .4KKKK ${c2}LJ ${c1}KKKKA. . .4
${c3}KKA. 'KKKKK ${c2}LJ ${c1}KKKKK' .4KK
${c3}KKSSA. VKKK ${c2}LJ ${c1}KKKV .4SSKK
${c2} <><><><>
'MKKM'
''
""")

View file

@ -0,0 +1,13 @@
from hyfetch.distro import AsciiArt
centos_small = AsciiArt(match=r'''"centos_small"*''', color='3 2 4 5 7', ascii=r"""
${c2} ____${c1}^${c4}____
${c2} |\\ ${c1}|${c4} /|
${c2} | \\ ${c1}|${c4} / |
${c4}<---- ${c3}---->
${c3} | / ${c2}|${c1} \\ |
${c3} |/__${c2}|${c1}__\\|
${c2} v
""")

24
tools/distros/chakra.py Normal file
View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
chakra = AsciiArt(match=r'''"Chakra"*''', color='4 5 7 6', ascii=r"""
${c1} _ _ _ "kkkkkkkk.
,kkkkkkkk., 'kkkkkkkkk,
,kkkkkkkkkkkk., 'kkkkkkkkk.
,kkkkkkkkkkkkkkkk,'kkkkkkkk,
,kkkkkkkkkkkkkkkkkkk'kkkkkkk.
"''"''',;::,,"''kkk''kkkkk; __
,kkkkkkkkkk, "k''kkkkk' ,kkkk
,kkkkkkk' ., ' .: 'kkkk',kkkkkk
,kkkkkkkk'.k' , ,kkkk;kkkkkkkkk
,kkkkkkkk';kk 'k "'k',kkkkkkkkkkkk
.kkkkkkkkk.kkkk.'kkkkkkkkkkkkkkkkkk'
;kkkkkkkk''kkkkkk;'kkkkkkkkkkkkk''
'kkkkkkk; 'kkkkkkkk.,""''"''""
''kkkk; 'kkkkkkkkkk.,
';' 'kkkkkkkkkkkk.,
';kkkkkkkkkk'
';kkkkkk'
"''"
""")

26
tools/distros/chaletos.py Normal file
View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
chaletos = AsciiArt(match=r'''"ChaletOS"*''', color='4 7 1', ascii=r"""
${c1} `.//+osso+/:``
`/sdNNmhyssssydmNNdo:`
:hNmy+-` .-+hNNs-
/mMh/` `+:` `+dMd:
.hMd- -sNNMNo. /yyy /mMs`
-NM+ `/dMd/--omNh::dMM `yMd`
.NN+ .sNNs:/dMNy:/hNmo/s yMd`
hMs `/hNd+-smMMMMMMd+:omNy- `dMo
:NM. .omMy:/hNMMMMMMMMMMNy:/hMd+` :Md`
/Md` `sm+.omMMMMMMMMMMMMMMMMd/-sm+ .MN:
/Md` MMMMMMMMMMMMMMMMMMMN .MN:
:NN. MMMMMMm....--NMMMMMN -Mm.
`dMo MMMMMMd mMMMMMN hMs
-MN: MMMMMMd mMMMMMN oMm`
:NM: MMMMMMd mMMMMMN +Mm-
-mMy. mmmmmmh dmmmmmh -hMh.
oNNs- :yMm/
.+mMdo:` `:smMd/`
-ohNNmhsoo++osshmNNh+.
`./+syyhhyys+:``
""")

24
tools/distros/chapeau.py Normal file
View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
chapeau = AsciiArt(match=r'''"Chapeau"*''', color='2 7', ascii=r"""
${c1} .-/-.
////////.
////////${c2}y+${c1}//.
////////${c2}mMN${c1}/////.
////////${c2}mMN+${c1}////////.
////////////////////////.
/////////+${c2}shhddhyo${c1}+////////.
////////${c2}ymMNmdhhdmNNdo${c1}///////.
///////+${c2}mMms${c1}////////${c2}hNMh${c1}///////.
///////${c2}NMm+${c1}//////////${c2}sMMh${c1}///////
//////${c2}oMMNmmmmmmmmmmmmMMm${c1}///////
//////${c2}+MMmssssssssssssss+${c1}///////
`//////${c2}yMMy${c1}////////////////////
`//////${c2}smMNhso++oydNm${c1}////////
`///////${c2}ohmNMMMNNdy+${c1}///////
`//////////${c2}++${c1}//////////
`////////////////.
-////////-
""")

24
tools/distros/chrom.py Normal file
View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
chrom = AsciiArt(match=r'''"Chrom"*''', color='2 1 3 4 7', ascii=r"""
${c2} .,:loool:,.
.,coooooooooooooc,.
.,lllllllllllllllllllll,.
;ccccccccccccccccccccccccc;
${c1} '${c2}ccccccccccccccccccccccccccccc.
${c1} ,oo${c2}c::::::::okO${c5}000${c3}0OOkkkkkkkkkkk:
${c1}.ooool${c2};;;;:x${c5}K0${c4}kxxxxxk${c5}0X${c3}K0000000000.
${c1}:oooool${c2};,;O${c5}K${c4}ddddddddddd${c5}KX${c3}000000000d
${c1}lllllool${c2};l${c5}N${c4}dllllllllllld${c5}N${c3}K000000000
${c1}lllllllll${c2}o${c5}M${c4}dccccccccccco${c5}W${c3}K000000000
${c1};cllllllllX${c5}X${c4}c:::::::::c${c5}0X${c3}000000000d
${c1}.ccccllllllO${c5}Nk${c4}c;,,,;cx${c5}KK${c3}0000000000.
${c1} .cccccclllllxOO${c5}OOO${c1}Okx${c3}O0000000000;
${c1} .:ccccccccllllllllo${c3}O0000000OOO,
${c1} ,:ccccccccclllcd${c3}0000OOOOOOl.
${c1} '::ccccccccc${c3}dOOOOOOOkx:.
${c1} ..,::cccc${c3}xOOOkkko;.
${c1} ..,:${c3}dOkxl:.
""")

View file

@ -0,0 +1,18 @@
from hyfetch.distro import AsciiArt
cleanjaro = AsciiArt(match=r'''"Cleanjaro"*''', color='7 7', ascii=r"""
${c1}
""")

View file

@ -0,0 +1,13 @@
from hyfetch.distro import AsciiArt
cleanjaro_small = AsciiArt(match=r'''"cleanjaro_small"*''', color='7 7', ascii=r"""
${c1}
""")

View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
clear_linux_os = AsciiArt(match=r'''"Clear Linux OS"* | "Clear_Linux"*''', color='4 3 7 6', ascii=r"""
${c1} BBB
BBBBBBBBB
BBBBBBBBBBBBBBB
BBBBBBBBBBBBBBBBBBBB
BBBBBBBBBBB BBB
BBBBBBBB${c2}YYYYY
${c1} BBBBBBBB${c2}YYYYYY
${c1} BBBBBBBB${c2}YYYYYYY
${c1} BBBBBBBBB${c2}YYYYY${c3}W
${c4} GG${c1}BBBBBBBY${c2}YYYY${c3}WWW
${c4} GGG${c1}BBBBBBB${c2}YY${c3}WWWWWWWW
${c4} GGGGGG${c1}BBBBBB${c3}WWWWWWWW
${c4} GGGGGGGG${c1}BBBB${c3}WWWWWWWW
${c4}GGGGGGGGGGG${c1}BBB${c3}WWWWWWW
${c4}GGGGGGGGGGGGG${c1}B${c3}WWWWWW
${c4}GGGGGGGG${c3}WWWWWWWWWWW
${c4}GG${c3}WWWWWWWWWWWWWWWW
WWWWWWWWWWWWWWWW
WWWWWWWWWW
WWW
""")

26
tools/distros/clearos.py Normal file
View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
clearos = AsciiArt(match=r'''"ClearOS"*''', color='2', ascii=r"""
${c1} `.--::::::--.`
.-:////////////////:-.
`-////////////////////////-`
-////////////////////////////-
`//////////////-..-//////////////`
./////////////: ://///////////.
`//////:..-////: :////-..-//////`
://////` -///:.``.:///-` ://///:
`///////:. -////////-` `:///////`
.//:--////:. -////-` `:////--://.
./: .////:. --` `:////- :/.
`//-` .////:. `:////- `-//`
:///-` .////:. `:////- `-///:
`/////-` -///: :///- `-/////`
`//////- `///: :///` .//////`
`:////: `///: :///` -////:`
.://: `///: :///` -//:.
.:: `///: :///` -:.
`///: :///`
`... ...`
""")

26
tools/distros/clover.py Normal file
View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
clover = AsciiArt(match=r'''"Clover"*''', color='2 6', ascii=r"""
${c1} `omo``omo`
`oNMMMNNMMMNo`
`oNMMMMMMMMMMMMNo`
oNMMMMMMMMMMMMMMMMNo
`sNMMMMMMMMMMMMMMNs`
`omo` `sNMMMMMMMMMMNs` `omo`
`oNMMMNo` `sNMMMMMMNs` `oNMMMNo`
`oNMMMMMMMNo` `oNMMNs` `oNMMMMMMMNo`
oNMMMMMMMMMMMNo` `sy` `oNMMMMMMMMMMMNo
`sNMMMMMMMMMMMMNo.${c2}oNNs${c1}.oNMMMMMMMMMMMMNs`
`oNMMMMMMMMMMMMNs.${c2}oNNs${c1}.oNMMMMMMMMMMMMNo`
oNMMMMMMMMMMMNs` `sy` `oNMMMMMMMMMMMNo
`oNMMMMMMMNs` `oNMMNo` `oNMMMMMMMNs`
`oNMMMNs` `sNMMMMMMNs` `oNMMMNs`
`oNs` `sNMMMMMMMMMMNs` `oNs`
`sNMMMMMMMMMMMMMMNs`
+NMMMMMMMMMMMMMMMMNo
`oNMMMMMMMMMMMMNo`
`oNMMMNNMMMNs`
`omo``oNs`
""")

23
tools/distros/condres.py Normal file
View file

@ -0,0 +1,23 @@
from hyfetch.distro import AsciiArt
condres = AsciiArt(match=r'''"Condres"*''', color='2 3 6', ascii=r"""
${c1}syyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy+${c3}.+.
${c1}`oyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy+${c3}:++.
${c2}/o${c1}+oyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy/${c3}oo++.
${c2}/y+${c1}syyyyyyyyyyyyyyyyyyyyyyyyyyyyy${c3}+ooo++.
${c2}/hy+${c1}oyyyhhhhhhhhhhhhhhyyyyyyyyy${c3}+oo+++++.
${c2}/hhh+${c1}shhhhhdddddhhhhhhhyyyyyyy${c3}+oo++++++.
${c2}/hhdd+${c1}oddddddddddddhhhhhyyyys${c3}+oo+++++++.
${c2}/hhddd+${c1}odmmmdddddddhhhhyyyy${c3}+ooo++++++++.
${c2}/hhdddmo${c1}odmmmdddddhhhhhyyy${c3}+oooo++++++++.
${c2}/hdddmmms${c1}/dmdddddhhhhyyys${c3}+oooo+++++++++.
${c2}/hddddmmmy${c1}/hdddhhhhyyyyo${c3}+oooo++++++++++:
${c2}/hhdddmmmmy${c1}:yhhhhyyyyy+${c3}+oooo+++++++++++:
${c2}/hhddddddddy${c1}-syyyyyys+${c3}ooooo++++++++++++:
${c2}/hhhddddddddy${c1}-+yyyy+${c3}/ooooo+++++++++++++:
${c2}/hhhhhdddddhhy${c1}./yo:${c3}+oooooo+++++++++++++/
${c2}/hhhhhhhhhhhhhy${c1}:-.${c3}+sooooo+++++++++++///:
${c2}:sssssssssssso++${c1}${c3}`:/:--------.````````
""")

View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
container_linux_by_coreos = AsciiArt(match=r'''"Container Linux by CoreOS"* | "Container_Linux"*''', color='4 7 1', ascii=r"""
${c1} .....
.';:cccccccc:;'.
':ccccclc${c3}lllllllll${c1}cc:.
.;cccccccc${c3}lllllllllllllll${c1}c,
;clllccccc${c3}llllllllllllllllll${c1}c,
.cllclccccc${c3}lllll${c2}lll${c3}llllllllllll${c1}c:
ccclclcccc${c3}cllll${c2}kWMMNKk${c3}llllllllll${c1}c:
:ccclclcccc${c3}llll${c2}oWMMMMMMWO${c3}lllllllll${c1}c,
.ccllllllccc${c3}clll${c2}OMMMMMMMMM0${c3}lllllllll${c1}c
.lllllclcccc${c3}llll${c2}KMMMMMMMMMMo${c3}llllllll${c1}c.
.lllllllcccc${c3}clll${c2}KMMMMMMMMN0${c3}lllllllll${c1}c.
.cclllllcccc${c3}lllld${c2}xkkxxdo${c3}llllllllllc${c1}lc
:cccllllllcccc${c3}lllccllllcclccc${c1}cccccc;
.ccclllllllcccccccc${c3}lll${c1}ccccclccccccc
.cllllllllllclcccclccclccllllcllc
:cllllllllccclcllllllllllllcc;
.cccccccccccccclcccccccccc:.
.;cccclccccccllllllccc,.
.';ccccclllccc:;..
.....
""")

24
tools/distros/crux.py Normal file
View file

@ -0,0 +1,24 @@
from hyfetch.distro import AsciiArt
crux = AsciiArt(match=r'''"CRUX"*''', color='4 5 7 6', ascii=r"""
${c1} odddd
oddxkkkxxdoo
ddcoddxxxdoool
xdclodod olol
xoc xdd olol
xdc ${c2}k00${c1}Okdlol
xxd${c2}kOKKKOkd${c1}ldd
xdco${c2}xOkdlo${c1}dldd
ddc:cl${c2}lll${c1}oooodo
odxxdd${c3}xkO000kx${c1}ooxdo
oxdd${c3}x0NMMMMMMWW0od${c1}kkxo
oooxd${c3}0WMMMMMMMMMW0o${c1}dxkx
docldkXW${c3}MMMMMMMWWN${c1}Odolco
xx${c2}dx${c1}kxxOKN${c3}WMMWN${c1}0xdoxo::c
${c2}xOkkO${c1}0oo${c3}odOW${c2}WW${c1}XkdodOxc:l
${c2}dkkkxkkk${c3}OKX${c2}NNNX0Oxx${c1}xc:cd
${c2} odxxdx${c3}xllod${c2}ddooxx${c1}dc:ldo
${c2} lodd${c1}dolccc${c2}ccox${c1}xoloo
""")

View file

@ -0,0 +1,13 @@
from hyfetch.distro import AsciiArt
crux_small = AsciiArt(match=r'''"crux_small" | KISS*''', color='4 5 7 6', ascii=r"""
${c1} ___
(${c3}.· ${c1}|
(${c2}<> ${c1}|
/ ${c3}__ ${c1}\\
( ${c3}/ \\ ${c1}/|
${c2}_${c1}/\\ ${c3}__)${c1}/${c2}_${c1})
${c2}\/${c1}-____${c2}\/
""")

View file

@ -0,0 +1,26 @@
from hyfetch.distro import AsciiArt
crystal_linux = AsciiArt(match=r'''*"Crystal Linux"*''', color='13 5', ascii=r"""
${c1} mysssym
${c1} mysssym
${c1} mysssym
${c1} mysssym
${c1} mysssyd
${c1} mysssyd N
${c1} mysssyd mysym
${c1} mysssyd dysssym
${c1} mysssyd dysssym
${c1} mysssyd dysssym
${c1} mysssyd dysssym
${c1} mysssyd dysssym
${c1} mysssyd dysssym
${c1} mysym dysssym
${c1} N dysssym
${c1} dysssym
${c1} dysssym
${c1} dysssym
${c1} dysssym
${c1} dysssym
""")

Some files were not shown because too many files have changed in this diff Show more