mirror of
https://github.com/dylanaraps/neofetch.git
synced 2025-10-04 09:08:38 +00:00
Compare commits
143 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
ed953cdf82 | ||
|
e7799892c0 | ||
|
33a1a8fb12 | ||
|
4d1ebbe600 | ||
|
9a7a213746 | ||
|
7a36f2fef0 | ||
|
1e2bde6dbe | ||
|
b21533d842 | ||
|
8891cce908 | ||
|
a314447afa | ||
|
d8ebd113ad | ||
|
530507614c | ||
|
c2fcf322d0 | ||
|
ece1f55183 | ||
|
bd6eb8e3f3 | ||
|
44fdd4d894 | ||
|
427fc68814 | ||
|
e4d51ed0d4 | ||
|
490bf1da70 | ||
|
071f776914 | ||
|
7e57c7eb59 | ||
|
012938e81d | ||
|
c22ff5ec91 | ||
|
31e7057fbc | ||
|
5981cb6eca | ||
|
4a0f02bde7 | ||
|
1335eb295b | ||
|
6ba5f78dee | ||
|
4c026be4cd | ||
|
958ac55617 | ||
|
7dd92aab9d | ||
|
13dde29326 | ||
|
362cbb5b7d | ||
|
0d2db03909 | ||
|
c4bd708a09 | ||
|
1b3e0e71bb | ||
|
bb2e0210de | ||
|
98f1a0e057 | ||
|
0427eb3f05 | ||
|
1b1bfa2dab | ||
|
b603d3395c | ||
|
9788d8b81c | ||
|
c8b41da31c | ||
|
a1c9452bda | ||
|
5e6cc26b93 | ||
|
e0be28a83d | ||
|
6fa9366006 | ||
|
9f851df3b4 | ||
|
9fc58aeb85 | ||
|
376e594c9d | ||
|
1d57507c01 | ||
|
0f0806ca06 | ||
|
362ae7b9d0 | ||
|
1cb6970c74 | ||
|
baa20e4115 | ||
|
884e38915f | ||
|
7d403db369 | ||
|
3bcd07b8f2 | ||
|
e3245fba63 | ||
|
b0cee7c7d7 | ||
|
182284bd05 | ||
|
49771d8925 | ||
|
8d2e2b5ee4 | ||
|
06797de423 | ||
|
2bdd52f1dc | ||
|
51791c5fcf | ||
|
dbf0d34dc7 | ||
|
6daade00ad | ||
|
d2df70f77d | ||
|
cb87a2095d | ||
|
4cc6fec6a0 | ||
|
191fb776b3 | ||
|
c0b36ad48c | ||
|
53dde789a6 | ||
|
9277ba2775 | ||
|
5c7cb81c27 | ||
|
32053b795e | ||
|
a588f88f6c | ||
|
96e05f78f8 | ||
|
33d0e5886b | ||
|
9f93bb681d | ||
|
6f46d44435 | ||
|
7132a82571 | ||
|
71e09d0d6d | ||
|
8470a256fd | ||
|
b5e95a8ce4 | ||
|
e6df26166a | ||
|
dc5eae2234 | ||
|
55c84d09b0 | ||
|
0c6e0048e8 | ||
|
6d30f5131f | ||
|
4d7e6be30c | ||
|
32110bc87e | ||
|
4f3c2e3b1f | ||
|
2e0e3f5d64 | ||
|
371bd64a8e | ||
|
9e7ad5c0ef | ||
|
3ea8a401bd | ||
|
203d2059a0 | ||
|
9bec0fef70 | ||
|
8da9015026 | ||
|
e28f873461 | ||
|
a81b4238df | ||
|
1ac98037d5 | ||
|
b61f33854a | ||
|
8a8441f6f9 | ||
|
cba1c4a72c | ||
|
fcefefee8b | ||
|
33f68b7c6f | ||
|
e050ba6d1a | ||
|
f1450d1fc8 | ||
|
f38da87a79 | ||
|
de8ab1eeb7 | ||
|
7ec516860a | ||
|
111caa6356 | ||
|
76d583a124 | ||
|
609e18a31c | ||
|
2f13ce79de | ||
|
3e9975c438 | ||
|
73d50eb6b8 | ||
|
ccc43cbcae | ||
|
924714b76d | ||
|
9a3a3bc83d | ||
|
74d4943115 | ||
|
a311897efd | ||
|
6a8f20c4c1 | ||
|
4a99a128f9 | ||
|
44ace4e837 | ||
|
daa56b0851 | ||
|
5ddd145bdc | ||
|
5e8953c7fa | ||
|
a850702843 | ||
|
9ab756b084 | ||
|
cbc33486f7 | ||
|
caf55803f3 | ||
|
5446b6afd5 | ||
|
438d5e0542 | ||
|
f15f5728ea | ||
|
a272874833 | ||
|
f053f5b8b2 | ||
|
4fe770cc3d | ||
|
0d78a6bdfe | ||
|
9d35c8e6d1 |
183
1.1.md
183
1.1.md
@@ -1,183 +0,0 @@
|
||||
# Fetch 1.1 changelog
|
||||
|
||||
Over the past 10~ days over **190** more commits have been pushed to master and the<br \>
|
||||
script has had some big changes. Thanks to everyone who has contributed, you've been<br \>
|
||||
a big help.
|
||||
|
||||
<br \>
|
||||
<sup>New screenfetch mode</sup>
|
||||
|
||||
- If `w3m` or `imagemagick` aren't installed we gracefully fallback to ascii mode.
|
||||
- Automatically find the `w3m-img` path and fallback to ascii mode if not found. \[1\]
|
||||
- Fix padding escape codes on BSD systems.
|
||||
- Swap escape codes from `\e` to `\033` for consistency.
|
||||
- We only move the cursor to the bottom of the terminal in w3m/iterm2 rendering modes.
|
||||
- Cursor position is now dynamic in ascii mode based on the height of the ascii and info text.
|
||||
- If images and ascii are off, don't clear the terminal
|
||||
- The script now exits correctly instead of always exiting with status code `1`
|
||||
- If the script exits for any reason, unhide the cursor.
|
||||
- Removed duplicate blocks inside `getcpu` and `getmemory`.
|
||||
- Removed `--colors` as it was apparently broken from day 1.
|
||||
- Usage has been reformatted so that every flag has a value.
|
||||
|
||||
\[1\] Setting `$w3m_img_path` will make the script look there first.
|
||||
|
||||
### Image
|
||||
|
||||
- Added support for displaying ascii art inside of text files.
|
||||
- Added "screenfetch mode" which will display your distro's ascii art next to the info. \[1\]<br \>
|
||||
- Added `--ascii_distro` to choose which distro's ascii logo to display.
|
||||
- Added `--ascii_colors` and `$ascii_colors` which allow you to change the colors of the ascii art<br \>
|
||||
and distro logos. \[2\]
|
||||
- Added `--size` and `$image_size` to set the image size in pixels.
|
||||
- Rename `--shuffledir` and `$shuffledir` to `shuffle_dir`.
|
||||
- Rename `--imgtempdir` and `$imgtempdir` to `thumbnail_dir`
|
||||
- Removed `--split_size` and `$split_size` as they were weird and confusing to use.
|
||||
- Default thumbnail directory is now `$HOME/.cache/thumbnails/fetch`. Thanks @tudurom
|
||||
- If `--image` and `--ascii` are left empty we fallback to ascii distro mode.
|
||||
|
||||
Example usage of ascii from file:
|
||||
|
||||
```sh
|
||||
fetch --ascii "path/to/ascii" --ascii_color 2
|
||||
|
||||
```
|
||||
|
||||
\[1\] **[How do I enable screenfetch mode?](http://github.com/dylanaraps/fetch#how-do-i-enable-screenfetch-mode)**<br \>
|
||||
\[2\] `ascii_colors` takes a range of colors which allows you to color every aspect of<br \>
|
||||
distro and OS ascii art. For custom art the script will color the entirety of it using<br \>
|
||||
the first value of `ascii_colors`. If `ascii_colors` is left empty, color will be disabled.
|
||||
|
||||
|
||||
### Config file
|
||||
|
||||
- Fetch now has a config file that you can share with people and keep between<br \>
|
||||
script versions!
|
||||
- Added `--config` and `$config_file` to specify a custom config location.
|
||||
- Added `--config off`, `--config none` and `$config` to enable / disable config files<br \>
|
||||
at launch or in script.
|
||||
|
||||
|
||||
### Makefile
|
||||
|
||||
- Fetch now has a make file due to the increasing number of files,<br \>
|
||||
this allows the script to be easily installed and uninstalled on<br \>
|
||||
systems it isn't packaged for yet! \[1\]
|
||||
|
||||
\[1\] The script will still work just fine on its own, you'll just be missing<br \>
|
||||
the distro ascii art and the automatic config creation.
|
||||
|
||||
|
||||
### Packages
|
||||
|
||||
- Fetch now has a Gentoo/Funtoo e-build courtesy of **@z1lt0id**
|
||||
|
||||
|
||||
### Stdout
|
||||
|
||||
- Added `stdout` mode which allows you to fetch info in a plain text format that works<br \>
|
||||
with lemonbar and in your scripts. You can use it by launching fetch with `--stdout` to print all<br \>
|
||||
functions enabled in your `printinfo` function. You can selectively print functions by passing<br \>
|
||||
arguments to `--stdout` like so:
|
||||
|
||||
```sh
|
||||
# Print the output of all info functions enabled in printinfo
|
||||
fetch --stdout
|
||||
|
||||
# Print the output of memory
|
||||
fetch --stdout memory
|
||||
|
||||
# Print the output of memory and disk
|
||||
fetch --stdout disk
|
||||
|
||||
# Print the output of all functions excluding x
|
||||
fetch --stdout --disable kernel packages gtktheme
|
||||
|
||||
```
|
||||
|
||||
- Added `--stdout_separator` and `$stdout_separator` which takes a string and adds it<br \>
|
||||
as a separator between the output.
|
||||
- Added `--stdout_title` and `$stdout_title` which allow you to toggle the `title@hostname`<br \>
|
||||
from appearing in the output.
|
||||
- Added `--stdout_subtitles` which allow you to toggle the `Info:` titles from appearing in<br \>
|
||||
the output.
|
||||
|
||||
```sh
|
||||
# Hiding subtitles
|
||||
fetch --stdout --stdout_subtitles off
|
||||
|
||||
# Custom separator
|
||||
fetch --stdout disk gpu --stdout_separator " | "
|
||||
|
||||
```
|
||||
|
||||
**NOTE:** `stdout_subtitles` and `stdout_title` only work when `--stdout` is used on its own<br \>
|
||||
without any args.
|
||||
|
||||
### Info
|
||||
|
||||
- You can now display info without a subtitle. eg. `info memory`
|
||||
- Added `--disable` which allows you to stop an info line from appearing at launch.<br \>
|
||||
- Added `--underline` and `$underline` which allow you to toggle visibility of the<br \>
|
||||
underline at launch and in your config.
|
||||
|
||||
```sh
|
||||
# Stop cpu, gpu, disk and shell functions from being called
|
||||
fetch --disable cpu gpu disk shell
|
||||
```
|
||||
|
||||
**Kernel:** Added `--kernel_shorthand` and `$kernel_shorthand` to print less or more kernel info<br \>
|
||||
**Window Manager:** Added support for `$XINITRC`<br \>
|
||||
**GTK:** Fix incorrect GTK3 theme being displayed<br \>
|
||||
**CPU:** `cpu_shorthand`: New substitutions<br \>
|
||||
**GPU:** `[Linux]` Count the number of identical GPUs. eg. `Nvidia Geforce GTX 970 x 2`<br \>
|
||||
**Memory:** `[Mac OS X]` Added wired memory to memory usage.<br \>
|
||||
|
||||
**Distro:**
|
||||
|
||||
- Added support for showing OS architecture. eg `Arch Linux x86_64`, `Windows 7 Ultimate 64-bit` \[1\]
|
||||
- Mac OS X: Added support for showing Max OS X build version. \[2\]
|
||||
- Windows: Distro now displays Windows edition. eg. `Windows 7 Ultimate`
|
||||
|
||||
\[1\] You can toggle this using `--os_arch` and `$os_arch`.<br \>
|
||||
\[2\] You can toggle it using `--osx_buildversion` and `$osx_buildversion`.
|
||||
|
||||
**Shell:**
|
||||
|
||||
- Added `--shell_version` and `$shell_version` to hide/show your shell's version.
|
||||
- Added `--shell_path` and `$shell_path` to hide/show the path to your shell
|
||||
|
||||
**Birthday:**
|
||||
|
||||
- Added `birthday` which prints the age of your OS install.
|
||||
- Added `--birthday_shorthand` and `$birthday_shorthand` to shorten/lengthen<br \>
|
||||
the output of birthday.
|
||||
- Added `--birthday_time` and `$birthday_time` to show/hide the time in the output.
|
||||
|
||||
**Battery:**
|
||||
|
||||
- Added `battery` which prints the battery usage percentage for each battery<br \>
|
||||
in your system.
|
||||
- Linux: Added `battery_num` which allows you to choose which battery to display, <br \>
|
||||
it also takes the value `all` which will print all batteries line by line.
|
||||
- Linux: Added `battery_shorthand` which when set to `on` prints each battery on the<br \>
|
||||
same line like so:
|
||||
|
||||
```sh
|
||||
# battery_shorthand="on"
|
||||
Battery: 10%, 5%, 67%
|
||||
|
||||
# battery_shorthand="off"
|
||||
Battery0: 10%
|
||||
Battery1: 5%
|
||||
Battery2: 67%
|
||||
|
||||
# If there's only a single battery in the system
|
||||
# we ommit the numbered title.
|
||||
Battery: 10%
|
||||
```
|
||||
|
||||
- **NOTE:** This currently doesn't support BSD systems as we have no one to help us test
|
||||
- See **[Issue #46](https://github.com/dylanaraps/fetch/issues/46)**
|
||||
|
||||
|
117
1.2.md
Normal file
117
1.2.md
Normal file
@@ -0,0 +1,117 @@
|
||||
# Fetch 1.2
|
||||
|
||||
This new release comes with a few config breaking changes, see this wiki page<br \>
|
||||
for info on how you can workaround the issues.
|
||||
|
||||
https://github.com/dylanaraps/fetch/wiki/Following-HEAD
|
||||
|
||||
- Fetch now has a **gitter** chatroom. [](https://gitter.im/dylanaraps/fetch?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
|
||||
- Fixed text padding when the user didn't have the locale `en_US.UTF8` installed.
|
||||
- Cleaned up parts of the script.
|
||||
|
||||
### OS
|
||||
|
||||
Fetch is now at support parity with Screenfetch. We support all the Linux distros<br \>
|
||||
Screenfetch supports excluding the distros that have been discontinued.
|
||||
|
||||
Added support for these distros:
|
||||
- `Puppy Linux`
|
||||
- `Kali Linux`
|
||||
- `openSUSE`
|
||||
- `Raspbian`
|
||||
- `Mageia`
|
||||
- `PCLinuxOS`
|
||||
- `Zorin OS`
|
||||
- `Tails`
|
||||
- `BLAG`
|
||||
- `Void Linux`
|
||||
- `Trisquel`
|
||||
- `Solus`
|
||||
- `Peppermint`
|
||||
- `NixOS`
|
||||
- `Chakra`
|
||||
- `Mandriva`
|
||||
- `gNewSense`
|
||||
- `LMDE`
|
||||
- `KaOS`
|
||||
- `Sabayon`
|
||||
- `Frugalware`
|
||||
- `Chapeau`
|
||||
- `Slackware`
|
||||
- `Scientific Linux`
|
||||
- `Exherbo`
|
||||
- `Chrome OS`
|
||||
- `Chromium OS`
|
||||
|
||||
|
||||
### Makefile
|
||||
|
||||
- Fixed makefile on OS X El Captain.
|
||||
- `$PREFIX` is now also used when installing ascii art and the default config
|
||||
|
||||
|
||||
### Wallpaper
|
||||
|
||||
- Fetch now supports using `MATE` desktop's wallpapers.
|
||||
- Fetch now fallsback to ascii mode if the found wallpaper is an xml file. This<br \>
|
||||
fixes issues where the wallpaper set by gsettings is an xml file.
|
||||
|
||||
|
||||
### Info
|
||||
|
||||
**Desktop Environment**:
|
||||
- Added support for showing the user's DE.
|
||||
|
||||
**Window Manager**:
|
||||
- `xprop` is now a required dependency. See **[#79](https://github.com/dylanaraps/fetch/issues/79)**
|
||||
- Renamed 'windowmanager' to 'wm'
|
||||
|
||||
**IP Address**:
|
||||
- Added function to get your local IP
|
||||
- Added function to get your public IP \[1\]
|
||||
- Added `--ip_host` and `$public_ip_host` which allow you to change the website we<br \>
|
||||
ping for the public IP.
|
||||
|
||||
\[1\] Public IP requires an internet connection as we ping a website.
|
||||
|
||||
**Packages**:
|
||||
- Check for packages based on which package manager is installed instead of<br \>
|
||||
using a hardcoded list of distros.
|
||||
|
||||
**Theme**:
|
||||
- Added support for getting DE theme.
|
||||
- Added support for getting KDE theme.
|
||||
- Renamed `getgtk` to `getstyle`.
|
||||
- Dropped the `gtk` from these printinfo functions `gtktheme`, `gtkicons`<br \>
|
||||
and `gtkfont`. Theme output will be blank until you make these changes:
|
||||
|
||||
```sh
|
||||
# Old Naming
|
||||
info "GTK Theme" gtktheme
|
||||
info "Icons" gtkicons
|
||||
info "Font" gtkfont
|
||||
|
||||
# New Naming
|
||||
info "Theme" theme
|
||||
info "Icons" icons
|
||||
info "Font" font
|
||||
```
|
||||
|
||||
**GPU**:
|
||||
- `gpu_shorthand` is now enabled by default.
|
||||
- We now favor showing the dedicated GPU over the integrated one.
|
||||
|
||||
**Song**:
|
||||
- Added support for `MOC`.
|
||||
- We now check to see if the player is running before printing anything.
|
||||
- We now check playback state and show it if relevent.
|
||||
|
||||
**Uptime**:
|
||||
- [Linux] Fixed uptime when it's under 1 minute.
|
||||
|
||||
|
||||
### Ascii Art
|
||||
- `--ascii_distro` now also enables ascii mode.
|
||||
- Fix missing ascii art when fetch is installed in /usr/local
|
||||
- Update Deepin's ascii art to their new logo
|
||||
|
@@ -9,9 +9,6 @@ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
|
20
Makefile
20
Makefile
@@ -1,21 +1,21 @@
|
||||
PREFIX ?= usr
|
||||
PREFIX ?= /usr
|
||||
RM ?= rm -f
|
||||
INSTALL_DIR ?= install -m755 -d
|
||||
INSTALL_PROG ?= install -m755 -D
|
||||
INSTALL_FILE ?= install -m644 -D
|
||||
INSTALL_PROG ?= install -m755
|
||||
INSTALL_FILE ?= install -m644
|
||||
|
||||
all:
|
||||
@echo Run \'make install\' to install Fetch
|
||||
|
||||
install:
|
||||
$(INSTALL_DIR) $(DESTDIR)/$(PREFIX)/bin
|
||||
$(INSTALL_DIR) $(DESTDIR)/usr/share/fetch/ascii/distro
|
||||
$(INSTALL_PROG) fetch $(DESTDIR)/$(PREFIX)/bin/fetch
|
||||
$(INSTALL_PROG) config/config $(DESTDIR)/usr/share/fetch/config
|
||||
$(INSTALL_PROG) ascii/distro/* $(DESTDIR)/usr/share/fetch/ascii/distro
|
||||
$(INSTALL_DIR) $(DESTDIR)$(PREFIX)/bin
|
||||
$(INSTALL_DIR) $(DESTDIR)$(PREFIX)/share/fetch/ascii/distro
|
||||
$(INSTALL_PROG) fetch $(DESTDIR)$(PREFIX)/bin/fetch
|
||||
$(INSTALL_PROG) config/config $(DESTDIR)$(PREFIX)/share/fetch/config
|
||||
$(INSTALL_PROG) ascii/distro/* $(DESTDIR)$(PREFIX)/share/fetch/ascii/distro
|
||||
|
||||
uninstall:
|
||||
$(RM) $(DESTDIR)/$(PREFIX)/bin/fetch
|
||||
$(RM) -r $(DESTDIR)/usr/share/fetch
|
||||
$(RM) $(DESTDIR)$(PREFIX)/bin/fetch
|
||||
$(RM) -r $(DESTDIR)$(PREFIX)/share/fetch
|
||||
|
||||
|
||||
|
24
README.md
24
README.md
@@ -1,5 +1,7 @@
|
||||
# fetch
|
||||
|
||||
[](https://gitter.im/dylanaraps/fetch?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
|
||||
|
||||
This is the home of my fetch script! This script gathers info <br />
|
||||
about your system and prints it to the terminal next to an image, <br \>
|
||||
your distro's logo or any ascii art of your choice!
|
||||
@@ -46,7 +48,7 @@ your distro's logo or any ascii art of your choice!
|
||||
|
||||
## Features
|
||||
|
||||
- Supports **Linux**, **Mac OS X**, **BSD** and **Windows** (Cygwin)
|
||||
- Supports **Linux**, **Mac OS X**, **BSD (FreeBSD, OpenBSD & NetBSD)** and **Windows** (Cygwin)
|
||||
- Display a **full color image**, a file containing **ascii art** or your **distro's logo** in ascii next to the info.
|
||||
- The script is **fast**. We use bash builtins wherever possible and only spawn external processes when necessary.
|
||||
- Take a screenshot of your desktop on script finish.
|
||||
@@ -65,8 +67,9 @@ your distro's logo or any ascii art of your choice!
|
||||
|
||||
### Required dependencies:
|
||||
|
||||
- `Bash 4.0+`
|
||||
- `procps-ng`
|
||||
- `Bash 4.0+`
|
||||
- `xprop` \[3\]
|
||||
- `procps-ng`
|
||||
- Not required on OS X
|
||||
|
||||
|
||||
@@ -77,7 +80,6 @@ your distro's logo or any ascii art of your choice!
|
||||
|
||||
##### Linux / BSD
|
||||
|
||||
- Window Manager: `wmctrl` \[3\]
|
||||
- Wallpaper: `feh`, `nitrogen` or `gsettings`
|
||||
- Current Song: `mpc` or `cmus`
|
||||
- Resolution: `xorg-xdpyinfo`
|
||||
@@ -88,8 +90,7 @@ your distro's logo or any ascii art of your choice!
|
||||
\[2\] You can enable the `iTerm2` image backend by using the launch flag `--image_backend iterm2` or by<br \>
|
||||
changing the config option `$image_backend` to `iterm2`.
|
||||
|
||||
\[3\] You should install wmctrl if the builtin window manager detection isn't working for you. The builtin<br \>
|
||||
detection works for most people and is generally faster which is why wmctrl isn't default.
|
||||
\[3\] See **[#79](https://github.com/dylanaraps/fetch/issues/79)** about why this is now a required dependency.
|
||||
|
||||
\[4\] You can use the launch flag `--scrot_cmd` or change the config option `$scrot_cmd` to your screenshot<br \>
|
||||
program's cmd and fetch will use it instead of scrot.
|
||||
@@ -103,6 +104,11 @@ program's cmd and fetch will use it instead of scrot.
|
||||
|
||||
## Installation
|
||||
|
||||
Those using a git version of fetch should check this page after<br \>
|
||||
updating, this page lists any breaking changes that were made and<br \>
|
||||
how you can workaround them.
|
||||
|
||||
https://github.com/dylanaraps/fetch/wiki/Following-HEAD
|
||||
|
||||
### Arch
|
||||
|
||||
@@ -125,6 +131,7 @@ program's cmd and fetch will use it instead of scrot.
|
||||
|
||||
1. Download the latest source at https://github.com/dylanaraps/fetch
|
||||
2. Run `make install` inside the script directory to install the script.
|
||||
- **El Captain**: `PREFIX=/usr/local make install`
|
||||
|
||||
**NOTE:** Fetch can be uninstalled easily using `make uninstall`.
|
||||
|
||||
@@ -238,8 +245,9 @@ alias fetch2="fetch \
|
||||
--shell_version on/off Enable/Disable showing \$SHELL version
|
||||
--battery_num num Which battery to display, default value is 'all'
|
||||
--battery_shorthand on/off Whether or not each battery gets its own line/title
|
||||
--ip_host url Url to ping for public IP
|
||||
--birthday_shorthand on/off Shorten the output of birthday
|
||||
--birthday_time on/ff Enable/Disable showing the time in birthday output
|
||||
--birthday_time on/off Enable/Disable showing the time in birthday output
|
||||
|
||||
Text Colors:
|
||||
--title_color num Change the color of the title
|
||||
@@ -272,8 +280,6 @@ alias fetch2="fetch \
|
||||
--shuffle_dir path/to/dir Which directory to shuffle for an image.
|
||||
--font_width px Used to automatically size the image
|
||||
--image_position left/right Where to display the image: (Left/Right)
|
||||
--split_size num Width of img/text splits, A value of 2 makes each
|
||||
split half the terminal width and etc.
|
||||
--crop_mode mode Which crop mode to use
|
||||
Takes the values: normal, fit, fill
|
||||
--crop_offset value Change the crop offset for normal mode.
|
||||
|
19
ascii/distro/blag
Normal file
19
ascii/distro/blag
Normal file
@@ -0,0 +1,19 @@
|
||||
"\
|
||||
${c1} d
|
||||
,MK:
|
||||
xMMMX:
|
||||
.NMMMMMX;
|
||||
lMMMMMMMM0clodkO0KXWW:
|
||||
KMMMMMMMMMMMMMMMMMMX'
|
||||
.;d0NMMMMMMMMMMMMMMMMMMK.
|
||||
.;dONMMMMMMMMMMMMMMMMMMMMMMx
|
||||
'dKMMMMMMMMMMMMMMMMMMMMMMMMl
|
||||
.:xKWMMMMMMMMMMMMMMMMMMM0.
|
||||
.:xNMMMMMMMMMMMMMMMMMK.
|
||||
lMMMMMMMMMMMMMMMMMMK.
|
||||
,MMMMMMMMWkOXWMMMMMM0
|
||||
.NMMMMMNd. \`':ldko
|
||||
OMMMK:
|
||||
oWk,
|
||||
;:
|
||||
"
|
20
ascii/distro/chakra
Normal file
20
ascii/distro/chakra
Normal file
@@ -0,0 +1,20 @@
|
||||
"\
|
||||
${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\'
|
||||
\"\'\'\"
|
||||
"
|
20
ascii/distro/chapeau
Normal file
20
ascii/distro/chapeau
Normal file
@@ -0,0 +1,20 @@
|
||||
"\
|
||||
${c2} .-/-.
|
||||
${c2} ////////.
|
||||
${c2} ////////${c1}y+${c2}//.
|
||||
${c2} ////////${c1}mMN${c2}/////.
|
||||
${c2} ////////${c1}mMN+${c2}////////.
|
||||
${c2} ////////////////////////.
|
||||
${c2} /////////+${c1}shhddhyo${c2}+////////.
|
||||
${c2} ////////${c1}ymMNmdhhdmNNdo${c2}///////.
|
||||
${c2} ///////+${c1}mMms${c2}////////${c1}hNMh${c2}///////.
|
||||
${c2} ///////${c1}NMm+${c2}//////////${c1}sMMh${c2}///////
|
||||
${c2} //////${c1}oMMNmmmmmmmmmmmmMMm${c2}///////
|
||||
${c2} //////${c1}+MMmssssssssssssss+${c2}///////
|
||||
${c2} \`//////${c1}yMMy${c2}////////////////////
|
||||
${c2} \`//////${c1}smMNhso++oydNm${c2}////////
|
||||
${c2} \`///////${c1}ohmNMMMNNdy+${c2}///////
|
||||
${c2} \`//////////${c1}++${c2}//////////
|
||||
${c2} \`////////////////.
|
||||
${c2} -////////-
|
||||
"
|
20
ascii/distro/chrome
Normal file
20
ascii/distro/chrome
Normal file
@@ -0,0 +1,20 @@
|
||||
"\
|
||||
${c2} .,:loool:,.
|
||||
${c2} .,coooooooooooooc,.
|
||||
${c2} .,lllllllllllllllllllll,.
|
||||
${c2} ;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:.
|
||||
"
|
@@ -1,18 +0,0 @@
|
||||
"\
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}████████████████████████████${c2} ${c1}███${c2}
|
||||
${c2} ${c1}████████████████████████████${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}████████████████████████████${c2} ${c1}███${c2}
|
||||
${c2} ${c1}████████████████████████████${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
${c2} ${c1}███${c2} ${c1}███${c2} ${c1}███${c2}
|
||||
"
|
@@ -1,21 +1,21 @@
|
||||
"\
|
||||
${c1} eeeeeeeeeeeeeeeeeeeeeeeeeeee
|
||||
${c1} eee eeeeeee eeeeeeee
|
||||
${c1}ee eeeeeeeee eeeeeeeee ee
|
||||
${c1}e eeeeeeeee eeeeeeeee e
|
||||
${c1}e eeeeeee eeeeeeeeee e
|
||||
${c1}e eeeeee eeeee e
|
||||
${c1}e eeeee eee eee e
|
||||
${c1}e eeeee ee eeeeee e
|
||||
${c1}e eeeee eee eee e
|
||||
${c1}e eeeeeeeeee eeee e
|
||||
${c1}e eeeee eeee e
|
||||
${c1}e eeeeee e
|
||||
${c1}e eeeeeee e
|
||||
${c1}e eee eeeeeeee e
|
||||
${c1}eeeeeeeeeeeeeeee e
|
||||
${c1}eeeeeeeeeeeee ee
|
||||
${c1} eeeeeeeeeee eee
|
||||
${c1} eeeeeeeeeeeeeeeeeeeeeeeeeeee
|
||||
${c1} ............
|
||||
.';;;;;. .,;,.
|
||||
.,;;;;;;;. ';;;;;;;.
|
||||
.;::::::::' .,::;;,''''',.
|
||||
,'.:::::::: .;;'. ';
|
||||
;' 'cccccc, ,' :: '.. .:
|
||||
,, :ccccc. ;: .c, '' :. ,;
|
||||
.l. cllll' ., .lc :; .l' l.
|
||||
.c :lllc ;cl: .l' .ll. :'
|
||||
.l 'looc. . ,o: 'oo' c,
|
||||
.o. .:ool::coc' .ooo' o.
|
||||
:: ..... .;dddo ;c
|
||||
l:... .';lddddo. ,o
|
||||
lxxxxxdoolllodxxxxxxxxxc :l
|
||||
,dxxxxxxxxxxxxxxxxxxl. 'o,
|
||||
,dkkkkkkkkkkkkko;. .;o;
|
||||
.;okkkkkdl;. .,cl:.
|
||||
.,:cccccccc:,.
|
||||
"
|
||||
|
||||
|
24
ascii/distro/exherbo
Normal file
24
ascii/distro/exherbo
Normal file
@@ -0,0 +1,24 @@
|
||||
"\
|
||||
${c1} ,
|
||||
${c1} OXo.
|
||||
${c1} NXdX0: .cok0KXNNXXK0ko:.
|
||||
${c1} KX '0XdKMMK;.xMMMk, .0MMMMMXx; ...
|
||||
${c1} 'NO..xWkMMx kMMM cMMMMMX,NMWOxOXd.
|
||||
${c1} cNMk NK .oXM. OMMMMO. 0MMNo kW.
|
||||
${c1} lMc o: ., .oKNk; ;NMMWlxW'
|
||||
${c1} ;Mc .. .,,' .0M${c2}g;${c1}WMN'dWMMMMMMO
|
||||
${c1} XX ,WMMMMW. cM${c2}cfli${c1}WMKlo. .kMk
|
||||
${c1} .Mo .WM${c2}GD${c1}MW. XM${c2}WO0${c1}MMk oMl
|
||||
${c1} ,M: ,XMMWx::,''oOK0x; NM.
|
||||
${c1} 'Ml ,kNKOxxxxxkkO0XXKOd:. oMk
|
||||
${c1} NK .0Nxc${c3}:::::::::::::::${c1}fkKNk, .MW
|
||||
${c1} ,Mo .NXc${c3}::${c1}qXWXb${c3}::::::::::${c1}oo${c3}::${c1}lNK. .MW
|
||||
${c1} ;Wo oMd${c3}:::${c1}oNMNP${c3}::::::::${c1}oWMMMx${c3}:${c1}c0M; lMO
|
||||
${c1} 'NO;W0c${c3}:::::::::::::::${c1}dMMMMO${c3}::${c1}lMk .WM'
|
||||
${c1} xWONXdc${c3}::::::::::::::${c1}oOOo${c3}::${c1}lXN. ,WMd
|
||||
${c1} 'KWWNXXK0Okxxo,${c3}:::::::${c1},lkKNo xMMO
|
||||
${c1} :XMNxl,';:lodxkOO000Oxc. .oWMMo
|
||||
${c1} 'dXMMXkl;,. .,o0MMNo'
|
||||
${c1} ':d0XWMMMMWNNNNMMMNOl'
|
||||
${c1} ':okKXWNKkl'
|
||||
"
|
25
ascii/distro/frugalware
Normal file
25
ascii/distro/frugalware
Normal file
@@ -0,0 +1,25 @@
|
||||
"\
|
||||
${c2} \`++/::-.\`
|
||||
${c2} /o+++++++++/::-.\`
|
||||
${c2} \`o+++++++++++++++o++/::-.\`
|
||||
${c2} /+++++++++++++++++++++++oo++/:-.\`\`
|
||||
${c2} .o+ooooooooooooooooooosssssssso++oo++/:-\`
|
||||
${c2} ++osoooooooooooosssssssssssssyyo+++++++o:
|
||||
${c2} -o+ssoooooooooooosssssssssssssyyo+++++++s\`
|
||||
${c2} o++ssoooooo++++++++++++++sssyyyyo++++++o:
|
||||
${c2} :o++ssoooooo${c1}/-------------${c2}+syyyyyo+++++oo
|
||||
${c2} \`o+++ssoooooo${c1}/-----${c2}+++++ooosyyyyyyo++++os:
|
||||
${c2} /o+++ssoooooo${c1}/-----${c2}ooooooosyyyyyyyo+oooss
|
||||
${c2} .o++++ssooooos${c1}/------------${c2}syyyyyyhsosssy-
|
||||
${c2} ++++++ssooooss${c1}/-----${c2}+++++ooyyhhhhhdssssso
|
||||
${c2} -s+++++syssssss${c1}/-----${c2}yyhhhhhhhhhhhddssssy.
|
||||
${c2} sooooooyhyyyyyh${c1}/-----${c2}hhhhhhhhhhhddddyssy+
|
||||
${c2} :yooooooyhyyyhhhyyyyyyhhhhhhhhhhdddddyssy\`
|
||||
${c2} yoooooooyhyyhhhhhhhhhhhhhhhhhhhddddddysy/
|
||||
${c2}-ysooooooydhhhhhhhhhhhddddddddddddddddssy
|
||||
${c2} .-:/+osssyyyysyyyyyyyyyyyyyyyyyyyyyyssy:
|
||||
${c2} \`\`.-/+oosysssssssssssssssssssssss
|
||||
${c2} \`\`.:/+osyysssssssssssssh.
|
||||
${c2} \`-:/+osyyssssyo
|
||||
${c2} .-:+++\`
|
||||
"
|
14
ascii/distro/gnewsense
Normal file
14
ascii/distro/gnewsense
Normal file
@@ -0,0 +1,14 @@
|
||||
"\
|
||||
${c1} ..,,,,..
|
||||
.oocchhhhhhhhhhccoo.
|
||||
.ochhlllllllc hhhhhh ollllllhhco.
|
||||
ochlllllllllll hhhllllllhhh lllllllllllhco
|
||||
.cllllllllllllll hlllllo +hllh llllllllllllllc.
|
||||
ollllllllllhco\'\' hlllllo +hllh \`\`ochllllllllllo
|
||||
hllllllllc\' hllllllllllllh \`cllllllllh
|
||||
ollllllh +llllllllllll+ hllllllo
|
||||
\`cllllh. ohllllllho .hllllc\'
|
||||
ochllc. ++++ .cllhco
|
||||
\`+occooo+. .+ooocco+\'
|
||||
\`+oo++++ ++++oo+\'
|
||||
"
|
18
ascii/distro/kaos
Normal file
18
ascii/distro/kaos
Normal file
@@ -0,0 +1,18 @@
|
||||
"\
|
||||
${c1} ████████ ████████
|
||||
${c1} ██████ ██████
|
||||
${c1} ████ ████
|
||||
${c1} █ █
|
||||
${c1} █
|
||||
${c1} █ ${c2} ████████ ████████
|
||||
${c1} █ ${c2} ██████ ██████
|
||||
${c1} █ ${c2} ████ ████
|
||||
${c1} █ ${c2} █ █
|
||||
${c1} █ ${c2} █
|
||||
${c1} ${c3}███████ ███████
|
||||
${c1} ${c3} █████ █████${c2} █
|
||||
${c1} █${c3} ███ ███ ${c2} █
|
||||
${c1} █ ${c3} █ ${c2} █
|
||||
${c1} █ ${c3}█ ${c2} █
|
||||
${c1} █ ${c3}█ ${c2} █
|
||||
"
|
19
ascii/distro/lmde
Normal file
19
ascii/distro/lmde
Normal file
@@ -0,0 +1,19 @@
|
||||
"\
|
||||
${c1}\`.-::---..
|
||||
${c2} .:++++ooooosssoo:.
|
||||
${c2} .+o++::. \`.:oos+.
|
||||
${c2} :oo:.\` -+oo${c1}:
|
||||
${c2} ${c1}\`${c2}+o/\` .${c1}::::::${c2}-. .++-${c1}\`
|
||||
${c2} ${c1}\`${c2}/s/ .yyyyyyyyyyo: +o-${c1}\`
|
||||
${c2} ${c1}\`${c2}so .ss ohyo\` :s-${c1}:
|
||||
${c2} ${c1}\`${c2}s/ .ss h m myy/ /s\`${c1}\`
|
||||
${c2} \`s: \`oo s m Myy+-o:\`
|
||||
${c2} \`oo :+sdoohyoydyso/.
|
||||
${c2} :o. .:////////++:
|
||||
${c2} \`/++ ${c1}-:::::-
|
||||
${c2} ${c1}\`${c2}++-
|
||||
${c2} ${c1}\`${c2}/+-
|
||||
${c2} ${c1}.${c2}+/.
|
||||
${c2} ${c1}.${c2}:+-.
|
||||
${c2} \`--.\`\`
|
||||
"
|
21
ascii/distro/mageia
Normal file
21
ascii/distro/mageia
Normal file
@@ -0,0 +1,21 @@
|
||||
"\
|
||||
${c2} .°°.
|
||||
${c2} °° .°°.
|
||||
${c2} .°°°. °°
|
||||
${c2} . .
|
||||
${c2} °°° .°°°.
|
||||
${c2} .°°°. '___'
|
||||
${c1} .${c2}'___' ${c1} .
|
||||
${c1} :dkxc;'. ..,cxkd;
|
||||
${c1} .dkk. kkkkkkkkkk .kkd.
|
||||
${c1} .dkk. ';cloolc;. .kkd
|
||||
${c1} ckk. .kk;
|
||||
${c1} xO: cOd
|
||||
${c1} xO: lOd
|
||||
${c1} lOO. .OO:
|
||||
${c1} .k00. .00x
|
||||
${c1} .k00; ;00O.
|
||||
${c1} .lO0Kc;,,,,,,;c0KOc.
|
||||
${c1} ;d00KKKKKK00d;
|
||||
${c1} .,KKKK,.
|
||||
"
|
21
ascii/distro/nixos
Normal file
21
ascii/distro/nixos
Normal file
@@ -0,0 +1,21 @@
|
||||
"\
|
||||
${c1} ::::. ${c2}'::::: ::::'
|
||||
${c1} '::::: ${c2}':::::. ::::'
|
||||
${c1} ::::: ${c2}'::::.:::::
|
||||
${c1} .......:::::..... ${c2}::::::::
|
||||
${c1} ::::::::::::::::::. ${c2}:::::: ${c1}::::.
|
||||
${c1} ::::::::::::::::::::: ${c2}:::::. ${c1}.::::'
|
||||
${c2} ..... ::::' ${c1}:::::'
|
||||
${c2} ::::: '::' ${c1}:::::'
|
||||
${c2} ........::::: ' ${c1}:::::::::::.
|
||||
${c2}::::::::::::: ${c1}:::::::::::::
|
||||
${c2} ::::::::::: ${c1}.. ${c1}:::::
|
||||
${c2} .::::: ${c1}.::: ${c1}:::::
|
||||
${c2} .::::: ${c1}::::: ${c1}''''' ${c2}.....
|
||||
${c2} ::::: ${c1}':::::. ${c2}......:::::::::::::'
|
||||
${c2} ::: ${c1}::::::. ${c2}':::::::::::::::::'
|
||||
${c1} .:::::::: ${c2}'::::::::::
|
||||
${c1} .::::''::::. ${c2}'::::.
|
||||
${c1} .::::' ::::. ${c2}'::::.
|
||||
${c1} .:::: :::: ${c2}'::::.
|
||||
"
|
17
ascii/distro/openmandriva
Normal file
17
ascii/distro/openmandriva
Normal file
@@ -0,0 +1,17 @@
|
||||
"\
|
||||
${c2} \`\`
|
||||
${c2} \`-.
|
||||
${c1} \` ${c2}.---
|
||||
${c1} -/ ${c2}-::--\`
|
||||
${c1} \`++ ${c2}\`----...\`\`\`-:::::.
|
||||
${c1} \`os. ${c2}.::::::::::::::-\`\`\` \` \`
|
||||
${c1} +s+ ${c2}.::::::::::::::::---...--\`
|
||||
${c1} -ss: ${c2}\`-::::::::::::::::-.\`\`.\`\`
|
||||
${c1} /ss- ${c2}.::::::::::::-.\`\` \`
|
||||
${c1} +ss: ${c2}.::::::::::::-
|
||||
${c1} /sso ${c2}.::::::-::::::-
|
||||
${c1} .sss/ ${c2}-:::-.\` .:::::
|
||||
${c1} /sss+. ${c2}..\`${c1} \`--\` ${c2}.:::
|
||||
${c1} -ossso+/:://+/-\` ${c2}.:\`
|
||||
${c1} -/+ooo+/-. ${c2}\`
|
||||
"
|
21
ascii/distro/pclinuxos
Normal file
21
ascii/distro/pclinuxos
Normal file
@@ -0,0 +1,21 @@
|
||||
"\
|
||||
${c1}mhhhyyyyhhhdN
|
||||
dyssyhhhhhhhhhhhssyhN
|
||||
Nysyhhyo/:-.....-/oyhhhssd
|
||||
Nsshhy+. \`/shhysm
|
||||
dohhy/ -shhsy
|
||||
dohhs\` /hhys
|
||||
N+hho ${c2}+ssssss+- .+syhys+ ${c1}/hhsy
|
||||
ohhh\` ${c2}ymmo++hmm+\`smmy/::+y\` ${c1}shh+
|
||||
+hho ${c2}ymm- /mmy+mms ${c1}:hhod
|
||||
/hh+ ${c2}ymmhhdmmh.smm/ ${c1}.hhsh
|
||||
+hhs ${c2}ymm+::-\` /mmy\` \` ${c1}/hh+m
|
||||
yyhh- ${c2}ymm- /dmdyosyd\` ${c1}\`yhh+
|
||||
ohhy\` ${c2}://\` -/+++/- ${c1}ohhom
|
||||
N+hhy- \`shhoh
|
||||
sshho. \`+hhyom
|
||||
dsyhhs/. \`:ohhhoy
|
||||
dysyhhhso///://+syhhhssh
|
||||
dhyssyhhhhhhyssyyhN
|
||||
mddhdhdmN
|
||||
"
|
21
ascii/distro/peppermint
Normal file
21
ascii/distro/peppermint
Normal file
@@ -0,0 +1,21 @@
|
||||
"\
|
||||
${c2} 8ZZZZZZ${c1}MMMMM
|
||||
${c2} .ZZZZZZZZZ${c1}MMMMMMM.
|
||||
${c1} MM${c2}ZZZZZZZZZ${c1}MMMMMMM${c2}ZZZZ
|
||||
${c1} MMMMM${c2}ZZZZZZZZ${c1}MMMMM${c2}ZZZZZZZM
|
||||
${c1} MMMMMMM${c2}ZZZZZZZ${c1}MMMM${c2}ZZZZZZZZZ.
|
||||
${c1} MMMMMMMMM${c2}ZZZZZZ${c1}MMM${c2}ZZZZZZZZZZZI
|
||||
${c1} MMMMMMMMMMM${c2}ZZZZZZ${c1}MM${c2}ZZZZZZZZZZ${c1}MMM
|
||||
${c2} .ZZZ${c1}MMMMMMMMMM${c2}IZZ${c1}MM${c2}ZZZZZ${c1}MMMMMMMMM
|
||||
${c2} ZZZZZZZ${c1}MMMMMMMM${c2}ZZ${c1}M${c2}ZZZZ${c1}MMMMMMMMMMM
|
||||
${c2} ZZZZZZZZZZZZZZZZ${c1}M${c2}Z${c1}MMMMMMMMMMMMMMM
|
||||
${c2} .ZZZZZZZZZZZZZ${c1}MMM${c2}Z${c1}M${c2}ZZZZZZZZZZ${c1}MMMM
|
||||
${c2} .ZZZZZZZZZZZ${c1}MMM${c2}7ZZ${c1}MM${c2}ZZZZZZZZZZ7${c1}M
|
||||
${c2} ZZZZZZZZZ${c1}MMMM${c2}ZZZZ${c1}MMMM${c2}ZZZZZZZ77
|
||||
${c1} MMMMMMMMMMMM${c2}ZZZZZ${c1}MMMM${c2}ZZZZZ77
|
||||
${c1} MMMMMMMMMM${c2}7ZZZZZZ${c1}MMMMM${c2}ZZ77
|
||||
${c1} .MMMMMMM${c2}ZZZZZZZZ${c1}MMMMM${c2}Z7Z
|
||||
${c1} MMMMM${c2}ZZZZZZZZZ${c1}MMMMMMM
|
||||
${c2} NZZZZZZZZZZZ${c1}MMMMM
|
||||
${c2} ZZZZZZZZZ${c1}MM)
|
||||
"
|
20
ascii/distro/puppy
Normal file
20
ascii/distro/puppy
Normal file
@@ -0,0 +1,20 @@
|
||||
"\
|
||||
${c1} \`-/osyyyysosyhhhhhyys+-
|
||||
${c1} -ohmNNmh+/hMMMMMMMMNNNNd+dMMMMNM+
|
||||
${c1} yMMMMNNmmddo/NMMMNNNNNNNNNo+NNNNNy
|
||||
${c1} .NNNNNNmmmddds:MMNNNNNNNNNNNh:mNNN/
|
||||
${c1} -NNNdyyyhdmmmd\`dNNNNNmmmmNNmdd/os/
|
||||
${c1} .Nm+shddyooo+/smNNNNmmmmNh. :mmd.
|
||||
${c1} NNNNy:\` ./hmmmmmmmNNNN: hNMh
|
||||
${c1} NMN- -++- +NNNNNNNNNNm+..-sMMMM-
|
||||
${c1} .MMo oNNNNo hNNNNNNNNmhdNNNMMMMM+
|
||||
${c1} .MMs /NNNN/ dNmhs+:-\` yMMMMMMMM+
|
||||
${c1} mMM+ .. \`sNN+. hMMMMhhMMM-
|
||||
${c1} +MMMmo:...:sNMMMMMms:\` hMMMMm.hMMy
|
||||
${c1} yMMMMMMMMMMMNdMMMMMM::/+o+//dMMd\`
|
||||
${c1} sMMMMMMMMMMN+:oyyo:sMMMNNMMMNy\`
|
||||
${c1} :mMMMMMMMMMMMmddNMMMMMMMMmh/
|
||||
${c1} /dMMMMMMMMMMMMMMMMMMNdy/\`
|
||||
${c1} .+hNMMMMMMMMMNmdhs/.
|
||||
${c1} .:/+ooo+/:-.
|
||||
"
|
20
ascii/distro/raspbian
Normal file
20
ascii/distro/raspbian
Normal file
@@ -0,0 +1,20 @@
|
||||
"\
|
||||
${c1} .',;:cc;,'. .,;::c:,,.
|
||||
${c1},ooolcloooo: 'oooooccloo:
|
||||
${c1}.looooc;;:ol :oc;;:ooooo'
|
||||
${c1};oooooo: ,ooooooc.
|
||||
${c1}.,:;'. .;:;'.
|
||||
${c2}.... ..'''''. ....
|
||||
${c2}.''. ..'''''. ..''.
|
||||
${c2}.. ..... ..... ..
|
||||
${c2}. .''''''' .''''''. .
|
||||
${c2}.'' .'''''''' .'''''''. ''.
|
||||
${c2}''' ''''''' .'''''' '''
|
||||
${c2}.' ........... ... .'.
|
||||
${c2}.... ''''''''. .''.
|
||||
${c2}'''''. ''''''''. .'''''
|
||||
${c2}'''''. .'''''. .'''''.
|
||||
${c2}..''. . .''..
|
||||
${c2}.'''''''
|
||||
${c2}......
|
||||
"
|
20
ascii/distro/sabayon
Normal file
20
ascii/distro/sabayon
Normal file
@@ -0,0 +1,20 @@
|
||||
"\
|
||||
${c2} ...........
|
||||
${c2} .. ..
|
||||
${c2} .. ..
|
||||
${c2} .. ${c1}o ${c2}..
|
||||
${c2} .. ${c1}:W' ${c2}..
|
||||
${c2} .. ${c1}.d. ${c2}..
|
||||
${c2}:. ${c1}.KNO ${c2}.:
|
||||
${c2}:. ${c1}cNNN. ${c2}.:
|
||||
${c2}: ${c1}dXXX, ${c2}:
|
||||
${c2}: ${c1}. dXXX, .cd, ${c2}:
|
||||
${c2}: ${c1}'kc .. dKKK. ,ll;:' ${c2}:
|
||||
${c2}: ${c1}.xkkxc;..dkkkc',cxkkl ${c2}:
|
||||
${c2}:. ${c1}.,cdddddddddddddo:. ${c2}.:
|
||||
${c2} .. ${c1}:lllllll: ${c2}..
|
||||
${c2} .. ${c1}',,,,, ${c2}..
|
||||
${c2} .. ..
|
||||
${c2} .. ..
|
||||
${c2} ...............
|
||||
"
|
22
ascii/distro/scientific
Normal file
22
ascii/distro/scientific
Normal file
@@ -0,0 +1,22 @@
|
||||
"\
|
||||
${c1} =/;;/-
|
||||
${c1} +: //
|
||||
${c1} /; /;
|
||||
${c1} -X H.
|
||||
${c1} .//;;;:;;-, X= :+ .-;:=;:;#;.
|
||||
${c1} M- ,=;;;#:, ,:#;;:=, ,@
|
||||
${c1} :# :#.=/++++/=.$= #=
|
||||
${c1} ,#; #/:+/;,,/++:+/ ;+.
|
||||
${c1} ,+/. ,;@+, ,#H;, ,/+,
|
||||
${c1} ;+;;/= @. ${c2}.H${c3}#${c2}#X ${c1}-X :///+;
|
||||
${c1} ;+=;;;.@, ${c3}.X${c2}M${c3}@$. ${c1}=X.//;=#/.
|
||||
${c1} ,;: :@#= =\$H: .+#-
|
||||
${c1} ,#= #;-///==///-// =#,
|
||||
${c1} ;+ :#-;;;:;;;;-X- +:
|
||||
${c1} @- .-;;;;M- =M/;;;-. -X
|
||||
${c1} :;;::;;-. #- :+ ,-;;-;:==
|
||||
${c1} ,X H.
|
||||
${c1} ;/ #=
|
||||
${c1} // +;
|
||||
${c1} '////'
|
||||
"
|
20
ascii/distro/solus
Normal file
20
ascii/distro/solus
Normal file
@@ -0,0 +1,20 @@
|
||||
"\
|
||||
${c1} e e
|
||||
${c1} eee ee
|
||||
${c1} eeee eee
|
||||
${c2} wwwwwwwww${c1}eeeeee
|
||||
${c2} wwwwwwwwwwwwwww${c1}eee
|
||||
${c2} wwwwwwwwwwwwwwwwwww${c1}eeeeeeee
|
||||
${c2} wwwww ${c1}eeeee${c2}wwwwww${c1}eeee
|
||||
${c2} www ${c1}eeee${c2}wwwwww${c1}e
|
||||
${c2} ww ${c1}ee${c2}wwwwww
|
||||
${c2} w wwwww
|
||||
${c2} wwwww
|
||||
${c2} wwwww
|
||||
${c2} wwwww
|
||||
${c2} wwww
|
||||
${c2} wwww
|
||||
${c2} wwww
|
||||
${c2} www
|
||||
${c2} ww
|
||||
"
|
21
ascii/distro/tails
Normal file
21
ascii/distro/tails
Normal file
@@ -0,0 +1,21 @@
|
||||
"\
|
||||
${c1} \`\`
|
||||
./yhNh
|
||||
syy/Nshh \`:o/
|
||||
N:dsNshh █ \`ohNMMd
|
||||
N-/+Nshh \`yMMMMd
|
||||
N-yhMshh yMMMMd
|
||||
N-s:hshh █ yMMMMd so//.
|
||||
N-oyNsyh yMMMMd d Mms.
|
||||
N:hohhhd:. yMMMMd syMMM+
|
||||
Nsyh+-..+y+- yMMMMd :mMM+
|
||||
+hy- -ss/\`yMMMM \`+d+
|
||||
:sy/. ./yNMMMMm \`\`
|
||||
.+ys- \`:+hNMMMMMMy/\`
|
||||
\`hNmmMMMMMMMMMMMMdo.
|
||||
dMMMMMMMMMMMMMMMMMNh:
|
||||
+hMMMMMMMMMMMMMMMMMmy.
|
||||
-oNMMMMMMMMMMmy+.\`
|
||||
\`:yNMMMds/.\`
|
||||
.//\`
|
||||
"
|
20
ascii/distro/trisquel
Normal file
20
ascii/distro/trisquel
Normal file
@@ -0,0 +1,20 @@
|
||||
"\
|
||||
${c1} ▄▄▄▄▄▄
|
||||
${c1} ▄█████████▄
|
||||
${c1} ▄▄▄▄▄▄ ████▀ ▀████
|
||||
${c1} ▄██████████▄ ████▀ ▄▄ ▀███
|
||||
${c1} ▄███▀▀ ▀▀████ ███▄ ▄█ ███
|
||||
${c1}▄███ ▄▄▄ ████▄ ▀██████ ▄███
|
||||
${c1}███ █▀▀██▄ █████▄ ▀▀ ▄████
|
||||
${c1}▀███ ███ ███████▄▄ ▄▄██████
|
||||
${c1} ▀███▄ ▄███ █████████████${c2}████▀
|
||||
${c1} ▀█████████ ███████${c2}███▀▀▀
|
||||
▀▀███▀▀ ██${c2}████▀▀
|
||||
${c2} ██████▀ ▄▄▄▄
|
||||
${c2} █████▀ ████████
|
||||
${c2} █████ ███▀ ▀███
|
||||
${c2} ████▄ ██▄▄▄ ███
|
||||
${c2} █████▄ ▀▀ ▄██
|
||||
${c2} ██████▄▄▄████
|
||||
${c2} ▀▀█████▀▀
|
||||
"
|
19
ascii/distro/zorin
Normal file
19
ascii/distro/zorin
Normal file
@@ -0,0 +1,19 @@
|
||||
"\
|
||||
${c1} \`osssssssssssssssssssso\`
|
||||
.osssssssssssssssssssssso.
|
||||
.+oooooooooooooooooooooooo+.
|
||||
|
||||
|
||||
\`::::::::::::::::::::::. .:\`
|
||||
\`+ssssssssssssssssss+:.\` \`.:+ssso\`
|
||||
.ossssssssssssssso/. \`-+ossssssso.
|
||||
ssssssssssssso/-\` \`-/osssssssssssss
|
||||
.ossssssso/-\` .-/ossssssssssssssso.
|
||||
\`+sss+:. \`.:+ssssssssssssssssss+\`
|
||||
\`:. .::::::::::::::::::::::\`
|
||||
|
||||
|
||||
.+oooooooooooooooooooooooo+.
|
||||
-osssssssssssssssssssssso-
|
||||
\`osssssssssssssssssssso\`
|
||||
"
|
@@ -26,17 +26,20 @@ printinfo () {
|
||||
info "Uptime" uptime
|
||||
info "Packages" packages
|
||||
info "Shell" shell
|
||||
info "Window Manager" windowmanager
|
||||
info "GTK Theme" gtktheme
|
||||
info "Icons" gtkicons
|
||||
info "Desktop Environment" de
|
||||
info "Window Manager" wm
|
||||
info "Theme" theme
|
||||
info "Icons" icons
|
||||
info "CPU" cpu
|
||||
info "GPU" gpu
|
||||
info "Memory" memory
|
||||
|
||||
# info "Font" gtkfont
|
||||
# info "Font" font
|
||||
# info "Disk" disk
|
||||
# info "Resolution" resolution
|
||||
# info "Battery" battery
|
||||
# info "Local IP" localip
|
||||
# info "Public IP" public
|
||||
# info "Birthday" birthday
|
||||
# info "Song" song
|
||||
# info "Visual Style" visualstyle
|
||||
@@ -96,7 +99,7 @@ speed_type="max"
|
||||
|
||||
# Shorten output of the getgpu funcion
|
||||
# --gpu_shorthand on/off
|
||||
gpu_shorthand="off"
|
||||
gpu_shorthand="on"
|
||||
|
||||
|
||||
# Gtk Theme / Icons
|
||||
@@ -130,6 +133,13 @@ battery_num="all"
|
||||
battery_shorthand="off"
|
||||
|
||||
|
||||
# IP Address
|
||||
|
||||
# Website to ping for the public IP
|
||||
# --ip_host url
|
||||
public_ip_host="http://ident.me"
|
||||
|
||||
|
||||
# Birthday
|
||||
|
||||
# Whether to show a long pretty output
|
||||
|
572
fetch
572
fetch
@@ -6,13 +6,12 @@
|
||||
#
|
||||
# Required Dependencies:
|
||||
# Bash 4.0+
|
||||
# Text formatting, dynamic image size and padding: tput
|
||||
# xprop
|
||||
# [Linux / BSD / Windows] Uptime detection: procps or procps-ng
|
||||
#
|
||||
# Optional Dependencies: (You'll lose these features without them)
|
||||
# Displaying Images: w3m + w3m-img
|
||||
# Image Cropping: ImageMagick
|
||||
# More accurate window manager detection: wmctrl
|
||||
# [ Linux / BSD ] Wallpaper Display: feh, nitrogen or gsettings
|
||||
# [ Linux / BSD ] Current Song: mpc or cmus
|
||||
# [ Linux / BSD ] Resolution detection: xorg-xdpyinfo
|
||||
@@ -21,10 +20,9 @@
|
||||
# https://github.com/dylanaraps/
|
||||
|
||||
# Speed up script by not using unicode
|
||||
SYS_LOCALE="$LANG"
|
||||
export LC_ALL=C
|
||||
export LANG=C
|
||||
export LANGUAGE=C
|
||||
|
||||
|
||||
# Config Options {{{
|
||||
|
||||
@@ -46,9 +44,10 @@ printinfo () {
|
||||
info "Uptime" uptime
|
||||
info "Packages" packages
|
||||
info "Shell" shell
|
||||
info "Window Manager" windowmanager
|
||||
info "GTK Theme" gtktheme
|
||||
info "Icons" gtkicons
|
||||
info "Desktop Environment" de
|
||||
info "Window Manager" wm
|
||||
info "Theme" theme
|
||||
info "Icons" icons
|
||||
info "CPU" cpu
|
||||
info "GPU" gpu
|
||||
info "Memory" memory
|
||||
@@ -58,6 +57,8 @@ printinfo () {
|
||||
# info "Resolution" resolution
|
||||
# info "Battery" battery
|
||||
# info "Song" song
|
||||
# info "Local IP" localip
|
||||
# info "Public IP" public
|
||||
# info "Birthday" birthday
|
||||
# info "Visual Style" visualstyle
|
||||
|
||||
@@ -116,7 +117,7 @@ speed_type="max"
|
||||
|
||||
# Shorten output of the getgpu funcion
|
||||
# --gpu_shorthand on/off
|
||||
gpu_shorthand="off"
|
||||
gpu_shorthand="on"
|
||||
|
||||
|
||||
# Gtk Theme / Icons
|
||||
@@ -150,6 +151,13 @@ battery_num="all"
|
||||
battery_shorthand="off"
|
||||
|
||||
|
||||
# IP Address
|
||||
|
||||
# Website to ping for the public IP
|
||||
# --ip_host url
|
||||
public_ip_host="http://ident.me"
|
||||
|
||||
|
||||
# Birthday
|
||||
|
||||
# Whether to show a long pretty output
|
||||
@@ -415,23 +423,27 @@ x32="x86"
|
||||
case "$os" in
|
||||
"Linux" )
|
||||
if type -p lsb_release >/dev/null 2>&1; then
|
||||
distro="$(lsb_release -a 2>/dev/null | awk -F':' '/Description/ {printf $2}')"
|
||||
distro="$(lsb_release -d 2>/dev/null | awk -F':' '/Description/ {printf $2}')"
|
||||
distro=${distro/[[:space:]]}
|
||||
|
||||
elif type -p crux >/dev/null 2>&1; then
|
||||
distro="CRUX"
|
||||
|
||||
else
|
||||
distro="$(grep -h '^NAME=' /etc/*ease)"
|
||||
distro=${distro#NAME\=*}
|
||||
distro=${distro#\"*}
|
||||
distro=${distro%*\"}
|
||||
|
||||
# Workaround for distros that store the value differently.
|
||||
[ -z "$distro" ] && distro="$(grep -h 'TAILS_PRODUCT_NAME' /etc/*ease)"
|
||||
[ -z "$distro" ] && distro="$(awk '/BLAG/ {print $1; exit}' /etc/*ease)"
|
||||
|
||||
distro=${distro/*NAME\=}
|
||||
distro=${distro//\"}
|
||||
fi
|
||||
;;
|
||||
|
||||
"Mac OS X")
|
||||
distro="Mac OS X $(sw_vers -productVersion)"
|
||||
|
||||
[ "$osx_buildversion" == "on" ] && \
|
||||
distro+=" $(sw_vers -buildVersion)"
|
||||
[ "$osx_buildversion" == "on" ] && distro+=" $(sw_vers -buildVersion)"
|
||||
;;
|
||||
|
||||
"OpenBSD")
|
||||
@@ -500,7 +512,22 @@ getkernel() {
|
||||
getuptime () {
|
||||
case "$os" in
|
||||
"Linux")
|
||||
uptime="$(uptime -p)"
|
||||
case "$distro" in
|
||||
"Puppy Linux"* | "Quirky Werewolf"* | "Precise Puppy"*)
|
||||
uptime=$(uptime | awk -F ':[0-9]{2}+ |(, ){1}+' '{printf $2}')
|
||||
uptime=${uptime/ / }
|
||||
;;
|
||||
|
||||
"openSUSE"*)
|
||||
uptime=$(uptime | awk -F ':[0-9]{2}+[a-z][a-z] |(, ){1}+' '{printf $2}')
|
||||
uptime=${uptime/ / }
|
||||
;;
|
||||
|
||||
*)
|
||||
uptime="$(uptime -p)"
|
||||
[ "$uptime" == "up " ] && uptime="up $(awk -F'.' '{print $1}' /proc/uptime) seconds"
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
|
||||
"Mac OS X" | *"BSD")
|
||||
@@ -554,6 +581,7 @@ getuptime () {
|
||||
uptime=${uptime/up}
|
||||
uptime=${uptime/minutes/mins}
|
||||
uptime=${uptime/minute/min}
|
||||
uptime=${uptime/seconds/secs}
|
||||
uptime=${uptime# }
|
||||
;;
|
||||
|
||||
@@ -565,6 +593,7 @@ getuptime () {
|
||||
uptime=${uptime/ hour/h}
|
||||
uptime=${uptime/ minutes/m}
|
||||
uptime=${uptime/ minute/m}
|
||||
uptime=${uptime/ seconds/s}
|
||||
uptime=${uptime/,}
|
||||
uptime=${uptime# }
|
||||
;;
|
||||
@@ -576,36 +605,49 @@ getuptime () {
|
||||
# Package Count {{{
|
||||
|
||||
getpackages () {
|
||||
case "$distro" in
|
||||
"Arch Linux"* | "Parabola"* | "Manjaro"* | "Antergos"*)
|
||||
packages="$(pacman -Qq --color never | wc -l)"
|
||||
case "$os" in
|
||||
"Linux")
|
||||
if type -p dpkg >/dev/null 2>&1; then
|
||||
packages="$(dpkg --get-selections | grep -cv deinstall$)"
|
||||
|
||||
elif type -p pacman >/dev/null 2>&1; then
|
||||
packages="$(pacman -Qq --color never | wc -l)"
|
||||
|
||||
elif type -p pkgtool >/dev/null 2>&1; then
|
||||
packages="$(ls -1 /var/log/packages | wc -l)"
|
||||
|
||||
elif type -p rpm >/dev/null 2>&1; then
|
||||
packages="$(rpm -qa | wc -l)"
|
||||
|
||||
elif type -p xbps-query >/dev/null 2>&1; then
|
||||
packages="$(xbps-query -l | wc -l)"
|
||||
|
||||
elif type -p pkginfo >/dev/null 2>&1; then
|
||||
packages="$(pkginfo -i | wc -l)"
|
||||
|
||||
elif type -p pisi >/dev/null 2>&1; then
|
||||
packages="$(pisi list-installed | wc -l)"
|
||||
|
||||
elif type -p pkg >/dev/null 2>&1; then
|
||||
packages="$(ls -1 /var/db/pkg | wc -l)"
|
||||
|
||||
elif type -p emerge >/dev/null 2>&1; then
|
||||
packages="$(ls -d /var/db/pkg/*/* | wc -l)"
|
||||
|
||||
elif type -p nix-env >/dev/null 2>&1; then
|
||||
packages="$(ls -d -1 /nix/store/*/ | wc -l)"
|
||||
|
||||
elif type -p pacman-g2 >/dev/null 2>&1; then
|
||||
packages="$(pacman-g2 -Q | wc -l)"
|
||||
|
||||
elif type -p cave >/dev/null 2>&1; then
|
||||
cross_packages=$(ls -d -1 /var/db/paludis/repositories/cross-installed/*/data/* | wc -l)
|
||||
packages=$(ls -d -1 /var/db/paludis/repositories/installed/data/* | wc -l)
|
||||
packages=$((packages + cross_packages))
|
||||
fi
|
||||
;;
|
||||
|
||||
"void"*)
|
||||
packages="$(xbps-query -l | wc -l)"
|
||||
;;
|
||||
|
||||
"Ubuntu"* | *"Mint"* | "CrunchBang"* | "Debian"* | "Kali Linux"* | "Deepin Linux"* | "elementary"*)
|
||||
packages="$(dpkg --get-selections | grep -cv deinstall$)"
|
||||
;;
|
||||
|
||||
"Slackware"*)
|
||||
packages="$(ls -1 /var/log/packages | wc -l)"
|
||||
;;
|
||||
|
||||
"Gentoo"* | "Funtoo"*)
|
||||
packages="$(ls -d /var/db/pkg/*/* | wc -l)"
|
||||
;;
|
||||
|
||||
"Fedora"* | "openSUSE"* | "Red Hat Enterprise Linux"* | "CentOS"*)
|
||||
packages="$(rpm -qa | wc -l)"
|
||||
;;
|
||||
|
||||
"CRUX"*)
|
||||
packages="$(pkginfo -i | wc -l)"
|
||||
;;
|
||||
|
||||
"Mac OS X"*)
|
||||
"Mac OS X")
|
||||
if [ -d "/usr/local/bin" ]; then
|
||||
local_packages=$(ls -l /usr/local/bin/ | grep -v "\(../Cellar/\|brew\)" | wc -l)
|
||||
packages=$((local_packages - 1))
|
||||
@@ -627,15 +669,16 @@ getpackages () {
|
||||
fi
|
||||
;;
|
||||
|
||||
"OpenBSD"* | "NetBSD"*)
|
||||
packages=$(pkg_info | wc -l)
|
||||
*"BSD")
|
||||
if type -p pkg_info >/dev/null 2>&1; then
|
||||
packages=$(pkg_info | wc -l)
|
||||
|
||||
elif type -p pkg >/dev/null 2>&1; then
|
||||
packages=$(pkg info | wc -l)
|
||||
fi
|
||||
;;
|
||||
|
||||
"FreeBSD"*)
|
||||
packages=$(pkg info | wc -l)
|
||||
;;
|
||||
|
||||
"Windows"*)
|
||||
"Windows")
|
||||
packages=$(cygcheck -cd | wc -l)
|
||||
|
||||
# Count chocolatey packages
|
||||
@@ -644,13 +687,10 @@ getpackages () {
|
||||
packages=$((packages + choco_packages))
|
||||
fi
|
||||
;;
|
||||
|
||||
*)
|
||||
packages="Unknown"
|
||||
;;
|
||||
esac
|
||||
|
||||
packages=${packages// }
|
||||
|
||||
[ -z "$packages" ] && packages="Unknown"
|
||||
}
|
||||
|
||||
# }}}
|
||||
@@ -694,33 +734,31 @@ getshell () {
|
||||
|
||||
# }}}
|
||||
|
||||
# Desktop Environment {{{
|
||||
|
||||
getde () {
|
||||
[ "$XDG_CURRENT_DESKTOP" ] && de="$XDG_CURRENT_DESKTOP"
|
||||
}
|
||||
|
||||
# }}}
|
||||
|
||||
# Window Manager {{{
|
||||
|
||||
getwindowmanager () {
|
||||
if type -p wmctrl >/dev/null 2>&1; then
|
||||
windowmanager="$(wmctrl -m | head -n1)"
|
||||
windowmanager=${windowmanager/Name: }
|
||||
|
||||
elif [ "$XDG_CURRENT_DESKTOP" ]; then
|
||||
windowmanager="$XDG_CURRENT_DESKTOP"
|
||||
|
||||
elif [ "$XINITRC" ]; then
|
||||
windowmanager=$(grep "^[^#]*exec" "$XINITRC")
|
||||
|
||||
elif [ -e "$HOME/.xinitrc" ]; then
|
||||
windowmanager=$(grep "^[^#]*exec" "${HOME}/.xinitrc")
|
||||
getwm () {
|
||||
if [ -n "$DISPLAY" ]; then
|
||||
id="$(xprop -root -notype | \awk '$1=="_NET_SUPPORTING_WM_CHECK:"{print $5}')"
|
||||
wm="$(xprop -id "$id" -notype -f _NET_WM_NAME 8t)"
|
||||
wm=${wm/*_NET_WM_NAME = }
|
||||
wm=${wm/\"}
|
||||
wm=${wm/\"*}
|
||||
|
||||
else
|
||||
case "$os" in
|
||||
"Mac OS X") windowmanager="Quartz Compositor" ;;
|
||||
"Windows") windowmanager="Explorer" ;;
|
||||
*) windowmanager="Unknown" ;;
|
||||
"Mac OS X") wm="Quartz Compositor" ;;
|
||||
"Windows") wm="Explorer" ;;
|
||||
*) wm="Unknown" ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
windowmanager="${windowmanager/exec }"
|
||||
windowmanager="${windowmanager/-session}"
|
||||
windowmanager="${windowmanager^}"
|
||||
}
|
||||
|
||||
# }}}
|
||||
@@ -734,6 +772,7 @@ getcpu () {
|
||||
cpu="$(grep -F 'model name' /proc/cpuinfo)"
|
||||
cpu=${cpu/model name*: }
|
||||
cpu=${cpu/ @*}
|
||||
cpu=${cpu// }
|
||||
cpu=${cpu%% }
|
||||
|
||||
# Get cpu speed
|
||||
@@ -848,13 +887,18 @@ getcpu () {
|
||||
getgpu () {
|
||||
case "$os" in
|
||||
"Linux")
|
||||
# Get the GPUs
|
||||
gpu="$(lspci | grep -F "VGA")"
|
||||
gpu="$(PATH="/sbin:$PATH" lspci | grep -F "3D")"
|
||||
|
||||
# If a GPU with a prefix of '3D' doesn't exist
|
||||
# fallback to looking for a prefix of 'VGA'
|
||||
[ -z "$gpu" ] && \
|
||||
gpu="$(PATH="/sbin:$PATH" lspci | grep -F "VGA")"
|
||||
gpu=${gpu//??':'??'.'?}
|
||||
|
||||
# Count the number of GPUs
|
||||
count="$(printf "%s" "$gpu" | uniq -c)"
|
||||
count=${count/ VGA*}
|
||||
count=${count/ 3D*}
|
||||
count=${count//[[:space:]]}
|
||||
|
||||
# If there's more than one gpu
|
||||
@@ -867,6 +911,7 @@ getgpu () {
|
||||
|
||||
# Format the output
|
||||
gpu=${gpu/* VGA compatible controller: }
|
||||
gpu=${gpu/* 3D controller: }
|
||||
gpu=${gpu/(rev*)}
|
||||
|
||||
shopt -s nocasematch
|
||||
@@ -874,6 +919,7 @@ getgpu () {
|
||||
intel*)
|
||||
gpu=${gpu/Intel Corporation }
|
||||
gpu=${gpu/Haswell-??? }
|
||||
gpu=${gpu/?th Gen Core Processor}
|
||||
|
||||
brand="Intel "
|
||||
;;
|
||||
@@ -884,6 +930,7 @@ getgpu () {
|
||||
gpu=${gpu/Tahiti PRO}
|
||||
gpu=${gpu/Seymour}
|
||||
gpu=${gpu/ OEM}
|
||||
gpu=${gpu/ Cape Verde}
|
||||
gpu=${gpu/ \[}
|
||||
gpu=${gpu/\]}
|
||||
|
||||
@@ -951,6 +998,7 @@ getgpu () {
|
||||
gpu=${gpu// OEM}
|
||||
gpu=${gpu// Mars}
|
||||
gpu=${gpu// Series}
|
||||
gpu=${gpu// Controller}
|
||||
gpu=${gpu/\/*}
|
||||
fi
|
||||
|
||||
@@ -1045,18 +1093,34 @@ getmemory () {
|
||||
# Song {{{
|
||||
|
||||
getsong () {
|
||||
if type -p mpc >/dev/null 2>&1; then
|
||||
song="$(mpc current)"
|
||||
if pgrep "mpd" >/dev/null 2>&1; then
|
||||
song="$(mpc current 2>/dev/null)"
|
||||
state=$(mpc | awk -F '\\[|\\]' '/\[/ {printf $2}' 2>/dev/null)
|
||||
|
||||
elif type -p cmus >/dev/null 2>&1; then
|
||||
song="$(cmus-remote -Q | grep "tag artist\|title")"
|
||||
elif pgrep "cmus" >/dev/null 2>&1; then
|
||||
song="$(cmus-remote -Q | grep "tag artist\|title" 2>/dev/null)"
|
||||
song=${song/tag artist }
|
||||
song=${song/tag title/-}
|
||||
song=${song//[[:space:]]/ }
|
||||
state=$(cmus-remote -Q | awk -F ' ' '/status/ {printf $2}' 2>/dev/null)
|
||||
|
||||
elif pgrep "mocp" >/dev/null 2>&1; then
|
||||
song="$(mocp -Q "%artist - %song" 2>/dev/null)"
|
||||
state="$(mocp -Q "%state" 2>/dev/null)"
|
||||
|
||||
else
|
||||
song="Unknown"
|
||||
fi
|
||||
|
||||
case "$state" in
|
||||
"paused" | "PAUSE")
|
||||
song="Paused"
|
||||
;;
|
||||
|
||||
"stopped" | "STOP" | "")
|
||||
song="Stopped"
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
# }}}
|
||||
@@ -1086,28 +1150,101 @@ getresolution () {
|
||||
|
||||
# }}}
|
||||
|
||||
# GTK Theme/Icons/Font {{{
|
||||
# Theme/Icons/Font {{{
|
||||
|
||||
getstyle () {
|
||||
# Fix weird output when the function
|
||||
# is run multiple times.
|
||||
unset gtk2theme gtk3theme
|
||||
|
||||
getgtk () {
|
||||
case "$1" in
|
||||
theme)
|
||||
name="gtk-theme-name"
|
||||
gsettings="gtk-theme"
|
||||
gconf="gtk_theme"
|
||||
xfconf="ThemeName"
|
||||
kde="widgetStyle"
|
||||
;;
|
||||
|
||||
icons)
|
||||
name="gtk-icon-theme-name"
|
||||
gsettings="icon-theme"
|
||||
gconf="icon_theme"
|
||||
xfconf="IconThemeName"
|
||||
kde="Theme"
|
||||
;;
|
||||
|
||||
font)
|
||||
name="gtk-font-name"
|
||||
gsettings="font-name"
|
||||
gconf="font_theme"
|
||||
xfconf="FontName"
|
||||
kde="font"
|
||||
;;
|
||||
esac
|
||||
|
||||
# Current DE
|
||||
desktop="$XDG_CURRENT_DESKTOP"
|
||||
desktop=${desktop,,}
|
||||
desktop=${desktop^}
|
||||
|
||||
case "$desktop" in
|
||||
"KDE"*)
|
||||
if type -p kde5-config >/dev/null 2>&1; then
|
||||
kde_config_dir=$(kde5-config --localprefix)
|
||||
|
||||
elif type -p kde4-config >/dev/null 2>&1; then
|
||||
kde_config_dir=$(kde4-config --localprefix)
|
||||
|
||||
elif type -p kde-config >/dev/null 2>&1; then
|
||||
kde_config_dir=$(kde-config --localprefix)
|
||||
fi
|
||||
|
||||
if [ -f "${kde_config_dir}/share/config/kdeglobals" ]; then
|
||||
kde_config_file="${kde_config_dir}/share/config/kdeglobals"
|
||||
|
||||
theme=$(grep "^[^#]*$kde" "$kde_config_file")
|
||||
theme=${theme/${kde}*=}
|
||||
theme=${theme^}
|
||||
|
||||
gtk_shorthand="on"
|
||||
return
|
||||
fi
|
||||
;;
|
||||
|
||||
"Cinnamon")
|
||||
if type -p gsettings >/dev/null 2>&1; then
|
||||
gtk3theme=$(gsettings get org.cinnamon.desktop.interface $gsettings)
|
||||
gtk3theme=${gtk3theme//"'"}
|
||||
gtk2theme=${gtk3theme}
|
||||
fi
|
||||
;;
|
||||
|
||||
"Gnome"* | "Unity"* | "Budgie")
|
||||
if type -p gsettings >/dev/null 2>&1; then
|
||||
gtk3theme=$(gsettings get org.gnome.desktop.interface $gsettings)
|
||||
gtk3theme=${gtk3theme//"'"}
|
||||
gtk2theme=${gtk3theme}
|
||||
|
||||
elif type -p gconftool-2 >/dev/null 2>&1; then
|
||||
gtk2theme=$(gconftool-2 -g /desktop/gnome/interface/$gconf)
|
||||
fi
|
||||
;;
|
||||
|
||||
"Mate"*)
|
||||
gtk3theme=$(gsettings get org.mate.interface $gsettings)
|
||||
gtk2theme=${gtk3theme}
|
||||
;;
|
||||
|
||||
"Xfce"*)
|
||||
if type -p xfconf-query >/dev/null 2>&1; then
|
||||
gtk2theme=$(xfconf-query -c xsettings -p /Net/$xfconf)
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
# Check for gtk2 theme
|
||||
if [ "$gtk2" == "on" ]; then
|
||||
if [ -z "$gtk2theme" ]; then
|
||||
if [ -f "$HOME/.gtkrc-2.0" ]; then
|
||||
gtk2theme=$(grep "^[^#]*$name" "$HOME/.gtkrc-2.0")
|
||||
|
||||
@@ -1120,7 +1257,7 @@ getgtk () {
|
||||
fi
|
||||
|
||||
# Check for gtk3 theme
|
||||
if [ "$gtk3" == "on" ]; then
|
||||
if [ -z "$gtk3theme" ]; then
|
||||
if [ -f "$HOME/.config/gtk-3.0/settings.ini" ]; then
|
||||
gtk3theme=$(grep "^[^#]*$name" "$HOME/.config/gtk-3.0/settings.ini")
|
||||
|
||||
@@ -1137,6 +1274,10 @@ getgtk () {
|
||||
gtk3theme=${gtk3theme/[[:space:]]/ }
|
||||
fi
|
||||
|
||||
# Toggle visibility of gtk themes.
|
||||
[ "$gtk2" == "off" ] && unset gtk2theme
|
||||
[ "$gtk3" == "off" ] && unset gtk3theme
|
||||
|
||||
# Format the string based on which themes exist
|
||||
if [ "$gtk2theme" ] && [ "$gtk2theme" == "$gtk3theme" ]; then
|
||||
gtk3theme+=" [GTK2/3]"
|
||||
@@ -1151,31 +1292,33 @@ getgtk () {
|
||||
fi
|
||||
|
||||
# Final string
|
||||
gtktheme="${gtk2theme}${gtk3theme}"
|
||||
theme="${gtk2theme}${gtk3theme}"
|
||||
theme=${theme//\"}
|
||||
theme=${theme//\'}
|
||||
|
||||
# If the final string is empty print "None"
|
||||
[ -z "$gtktheme" ] && gtktheme="None"
|
||||
[ -z "$theme" ] && theme="None"
|
||||
|
||||
# Make the output shorter by removing "[GTKX]" from the string
|
||||
if [ "$gtk_shorthand" == "on" ]; then
|
||||
gtktheme=${gtktheme/ '[GTK2]'}
|
||||
gtktheme=${gtktheme/ '[GTK3]'}
|
||||
gtktheme=${gtktheme/ '[GTK2/3]'}
|
||||
theme=${theme/ '[GTK2]'}
|
||||
theme=${theme/ '[GTK3]'}
|
||||
theme=${theme/ '[GTK2/3]'}
|
||||
fi
|
||||
}
|
||||
|
||||
getgtktheme () {
|
||||
getgtk theme
|
||||
gettheme () {
|
||||
getstyle theme
|
||||
}
|
||||
|
||||
getgtkicons () {
|
||||
getgtk icons
|
||||
gtkicons="$gtktheme"
|
||||
geticons () {
|
||||
getstyle icons
|
||||
icons="$theme"
|
||||
}
|
||||
|
||||
getgtkfont () {
|
||||
getgtk font
|
||||
gtkfont="$gtktheme"
|
||||
getfont () {
|
||||
getstyle font
|
||||
font="$theme"
|
||||
}
|
||||
|
||||
# }}}
|
||||
@@ -1270,6 +1413,47 @@ getbattery () {
|
||||
|
||||
# }}}
|
||||
|
||||
# IP Address {{{
|
||||
|
||||
getlocalip () {
|
||||
case "$os" in
|
||||
"Linux")
|
||||
localip="$(ip route get 1 | awk '{print $NF;exit}')"
|
||||
;;
|
||||
|
||||
"Mac OS X")
|
||||
localip="$(ipconfig getifaddr en0)"
|
||||
[ -z "$localip" ] && localip="$(ipconfig getifaddr en1)"
|
||||
;;
|
||||
|
||||
*"BSD")
|
||||
localip="$(ifconfig | awk '/broadcast/ {print $2}')"
|
||||
;;
|
||||
|
||||
"Windows")
|
||||
localip="$(ipconfig | awk -F ': ' '/IPv4 Address/ {printf $2}')"
|
||||
;;
|
||||
|
||||
*)
|
||||
localip="Unknown"
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
getpublicip () {
|
||||
if type -p curl >/dev/null 2>&1; then
|
||||
publicip="$(curl -w '\n' "$public_ip_host")"
|
||||
|
||||
elif type -p wget >/dev/null 2>&1; then
|
||||
publicip="$(wget -qO- "$public_ip_host"; printf "%s")"
|
||||
|
||||
else
|
||||
publicip="Unknown"
|
||||
fi
|
||||
}
|
||||
|
||||
# }}}
|
||||
|
||||
# Birthday {{{
|
||||
|
||||
getbirthday () {
|
||||
@@ -1395,7 +1579,12 @@ getwallpaper () {
|
||||
img="$(awk -F'=' '/file/ {printf $2}' "$HOME/.config/nitrogen/bg-saved.cfg")"
|
||||
|
||||
elif type -p gsettings >/dev/null 2>&1; then
|
||||
img="$(gsettings get org.gnome.desktop.background picture-uri 2>/dev/null)"
|
||||
case "$XDG_CURRENT_DESKTOP" in
|
||||
"MATE"*) img="$(gsettings get org.mate.background picture-filename 2>/dev/null)" ;;
|
||||
*) img="$(gsettings get org.gnome.desktop.background picture-uri 2>/dev/null)" ;;
|
||||
esac
|
||||
|
||||
# Strip quotes etc from the path.
|
||||
img=${img/'file://'}
|
||||
img=${img//\'}
|
||||
fi
|
||||
@@ -1420,6 +1609,9 @@ getwallpaper () {
|
||||
esac
|
||||
;;
|
||||
esac
|
||||
|
||||
# If img is an xml file don't use it.
|
||||
[ "${img/*\./}" == "xml" ] && img=""
|
||||
}
|
||||
|
||||
# }}}
|
||||
@@ -1431,99 +1623,119 @@ getascii () {
|
||||
shopt -s nocasematch
|
||||
case "$ascii_distro" in
|
||||
"Arch Linux"* | "Antergos"*)
|
||||
c1=$(color 6)
|
||||
c2=$(color 4)
|
||||
ascii_colors 6 4
|
||||
;;
|
||||
|
||||
"CentOS"*)
|
||||
c1=$(color 3)
|
||||
c2=$(color 2)
|
||||
c3=$(color 4)
|
||||
c4=$(color 5)
|
||||
c5=$(color 7)
|
||||
ascii_colors 3 2 4 5 7
|
||||
;;
|
||||
|
||||
"CRUX")
|
||||
c1=$(color 4)
|
||||
c2=$(color 5)
|
||||
c3=$(color 7)
|
||||
"CRUX"* | "Chakra"* | "gNewSense"*)
|
||||
ascii_colors 4 5 7
|
||||
;;
|
||||
|
||||
"Debian"* | "FreeBSD"* | "Red Hat"* | "elementary"* | "CrunchBang"* | "Ubuntu"*)
|
||||
c1=$(color 7)
|
||||
c2=$(color 1)
|
||||
c3=$(color 3)
|
||||
"Chrom"*)
|
||||
ascii_colors 2 1 3 4 7
|
||||
ascii_distro="chrome"
|
||||
;;
|
||||
|
||||
"Fedora"*)
|
||||
c1=$(color 7)
|
||||
c2=$(color 4)
|
||||
"Debian"* | "FreeBSD"* | "Elementary"* | "CrunchBang"* | "Ubuntu"*)
|
||||
ascii_colors 7 1 3
|
||||
;;
|
||||
|
||||
"Red Hat"*)
|
||||
ascii_colors 7 1 3
|
||||
ascii_distro="redhat"
|
||||
;;
|
||||
|
||||
"Fedora"* | "Sabayon"* | "Frugalware"* | "Exherbo"*)
|
||||
ascii_colors 7 4 1
|
||||
;;
|
||||
|
||||
"Gentoo"* | "Funtoo"*)
|
||||
c1=$(color 7)
|
||||
c2=$(color 5)
|
||||
ascii_colors 7 5
|
||||
;;
|
||||
|
||||
"Kali"*)
|
||||
c1=$(color 4)
|
||||
c2=$(color 8)
|
||||
ascii_colors 4 8
|
||||
;;
|
||||
|
||||
"KaOS"*)
|
||||
ascii_colors 4 7 1
|
||||
;;
|
||||
|
||||
"Mac OS X"* | "Manjaro"* | "Deepin"*)
|
||||
c1=$(color 2)
|
||||
c2=$(color 3)
|
||||
c3=$(color 1)
|
||||
c4=$(color 1)
|
||||
c5=$(color 5)
|
||||
c6=$(color 4)
|
||||
ascii_colors 2 3 1 1 5 4
|
||||
;;
|
||||
|
||||
"OpenMandriva"*)
|
||||
ascii_colors 4 3
|
||||
;;
|
||||
|
||||
"Mageia"*)
|
||||
ascii_colors 7 6
|
||||
;;
|
||||
|
||||
"Peppermint"*)
|
||||
ascii_colors 7 1
|
||||
;;
|
||||
|
||||
*"Mint"*)
|
||||
c1=$(color 7)
|
||||
c2=$(color 2)
|
||||
ascii_colors 7 2
|
||||
ascii_distro="mint"
|
||||
;;
|
||||
|
||||
"NetBSD"* | "Parabola"*)
|
||||
c1=$(color 5)
|
||||
c2=$(color 7)
|
||||
"LMDE"* | "Chapeau"*)
|
||||
ascii_colors 7 2
|
||||
;;
|
||||
|
||||
"NetBSD"* | "Parabola"* | "Tails"* | "BLAG"*)
|
||||
ascii_colors 5 7
|
||||
;;
|
||||
|
||||
"OpenBSD"*)
|
||||
c1=$(color 3)
|
||||
c2=$(color 3)
|
||||
c3=$(color 6)
|
||||
c4=$(color 1)
|
||||
c5=$(color 8)
|
||||
ascii_colors 3 3 6 1 8
|
||||
;;
|
||||
|
||||
"OpenSuse"*)
|
||||
c1=$(color 2)
|
||||
c2=$(color 7)
|
||||
ascii_colors 2 7
|
||||
;;
|
||||
|
||||
"Slackware"*)
|
||||
c1=$(color 4)
|
||||
c2=$(color 7)
|
||||
"PCLinuxOS"* | "Slackware"*)
|
||||
ascii_colors 4 7
|
||||
;;
|
||||
|
||||
"Raspbian"*)
|
||||
ascii_colors 2 1
|
||||
;;
|
||||
|
||||
"Scientific"*)
|
||||
ascii_colors 4 1 7
|
||||
;;
|
||||
|
||||
"Solus"*)
|
||||
ascii_colors 7 8
|
||||
;;
|
||||
|
||||
"Trisquel"* | "NixOS"*)
|
||||
ascii_colors 4 6
|
||||
;;
|
||||
|
||||
"void"*)
|
||||
c1=$(color 2)
|
||||
c2=$(color 2)
|
||||
c3=$(color 8)
|
||||
ascii_colors 2 2 8
|
||||
;;
|
||||
|
||||
"Windows 10"*)
|
||||
c1=$(color 6)
|
||||
ascii_colors 6
|
||||
ascii_distro="windows10"
|
||||
;;
|
||||
|
||||
"Windows"*)
|
||||
c1=$(color 1)
|
||||
c2=$(color 2)
|
||||
c3=$(color 4)
|
||||
c4=$(color 3)
|
||||
ascii_colors 1 2 4 3
|
||||
;;
|
||||
|
||||
"Zorin"*)
|
||||
ascii_colors 4
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -1539,6 +1751,10 @@ getascii () {
|
||||
# looking in the script's directory.
|
||||
if [ -f "/usr/share/fetch/ascii/distro/${ascii/ *}" ]; then
|
||||
ascii="/usr/share/fetch/ascii/distro/${ascii/ *}"
|
||||
|
||||
elif [ -f "/usr/local/share/fetch/ascii/distro/${ascii/ *}" ]; then
|
||||
ascii="/usr/local/share/fetch/ascii/distro/${ascii/ *}"
|
||||
|
||||
else
|
||||
getscriptdir
|
||||
|
||||
@@ -1555,14 +1771,8 @@ getascii () {
|
||||
|
||||
# Overwrite distro colors if '$ascii_colors' doesn't
|
||||
# equal 'distro'.
|
||||
if [ "$ascii_colors" != "distro" ]; then
|
||||
c1=$(color ${ascii_colors[0]})
|
||||
c2=$(color ${ascii_colors[1]})
|
||||
c3=$(color ${ascii_colors[2]})
|
||||
c4=$(color ${ascii_colors[3]})
|
||||
c5=$(color ${ascii_colors[4]})
|
||||
c6=$(color ${ascii_colors[5]})
|
||||
fi
|
||||
[ "${ascii_colors[0]}" != "distro" ] && \
|
||||
ascii_colors ${ascii_colors[@]}
|
||||
|
||||
# We only use eval in the distro ascii files.
|
||||
print="$(eval printf "$(<"$ascii")")"
|
||||
@@ -1575,6 +1785,9 @@ getascii () {
|
||||
print="${ascii_color}$(<"$ascii")"
|
||||
fi
|
||||
|
||||
# Set locale to get correct padding
|
||||
export LC_ALL="$SYS_LOCALE"
|
||||
|
||||
# Turn the file into a variable.
|
||||
ascii_strip=$(<"$ascii")
|
||||
|
||||
@@ -1583,20 +1796,32 @@ getascii () {
|
||||
ascii_strip=${ascii_strip//\\}
|
||||
|
||||
# Get length of longest line
|
||||
length="$(LC_ALL="en_US.UTF8" wc -L 2>/dev/null <<< "$ascii_strip")"
|
||||
length="$(wc -L 2>/dev/null <<< "$ascii_strip")"
|
||||
|
||||
# Get the height in lines
|
||||
lines="$(($(LC_ALL="en_US.UTF8" wc -l 2>/dev/null <<< "$ascii_strip") + 1))"
|
||||
lines="$(($(wc -l 2>/dev/null <<< "$ascii_strip") + 1))"
|
||||
|
||||
# Fallback to using awk on systems without 'wc -L'
|
||||
[ -z "$length" ] && \
|
||||
length="$(LC_ALL="en_US.UTF8" awk 'length>max{max=length}END{print max}' <<< "$ascii_strip")"
|
||||
length="$(awk 'length>max{max=length}END{print max}' <<< "$ascii_strip")"
|
||||
|
||||
# Set the text padding
|
||||
padding="\033[$((length + gap))C"
|
||||
|
||||
# Print the ascii
|
||||
printf "%b%s" "$print"
|
||||
|
||||
# Set locale to get correct padding
|
||||
export LC_ALL=C
|
||||
}
|
||||
|
||||
ascii_colors () {
|
||||
c1=$(color "$1")
|
||||
c2=$(color "$2")
|
||||
c3=$(color "$3")
|
||||
c4=$(color "$4")
|
||||
c5=$(color "$5")
|
||||
c6=$(color "$6")
|
||||
}
|
||||
|
||||
|
||||
@@ -1980,20 +2205,25 @@ getconfig () {
|
||||
return
|
||||
fi
|
||||
|
||||
# Make the directory if it doesn't exist
|
||||
mkdir -p "$HOME/.config/fetch/"
|
||||
|
||||
# Check $HOME/.config/fetch and create the
|
||||
# dir/files if they don't exist.
|
||||
if [ -f "$HOME/.config/fetch/config" ]; then
|
||||
source "$HOME/.config/fetch/config"
|
||||
|
||||
elif [ -f "/usr/share/fetch/config" ]; then
|
||||
mkdir -p "$HOME/.config/fetch/"
|
||||
cp "/usr/share/fetch/config" "$HOME/.config/fetch"
|
||||
source "$HOME/.config/fetch/config"
|
||||
|
||||
elif [ -f "/usr/local/share/fetch/config" ]; then
|
||||
cp "/usr/local/share/fetch/config" "$HOME/.config/fetch"
|
||||
source "$HOME/.config/fetch/config"
|
||||
|
||||
else
|
||||
getscriptdir
|
||||
|
||||
mkdir -p "$HOME/.config/fetch/"
|
||||
cp "$script_dir/config/config" "$HOME/.config/fetch"
|
||||
source "$HOME/.config/fetch/config"
|
||||
fi
|
||||
@@ -2044,8 +2274,9 @@ usage () { cat << EOF
|
||||
--shell_version on/off Enable/Disable showing \$SHELL version
|
||||
--battery_num num Which battery to display, default value is 'all'
|
||||
--battery_shorthand on/off Whether or not each battery gets its own line/title
|
||||
--ip_host url Url to ping for public IP
|
||||
--birthday_shorthand on/off Shorten the output of birthday
|
||||
--birthday_time on/ff Enable/Disable showing the time in birthday output
|
||||
--birthday_time on/off Enable/Disable showing the time in birthday output
|
||||
|
||||
Text Colors:
|
||||
--title_color num Change the color of the title
|
||||
@@ -2148,6 +2379,7 @@ while [ "$1" ]; do
|
||||
--shell_version) shell_version="$2" ;;
|
||||
--battery_num) battery_num="$2" ;;
|
||||
--battery_shorthand) battery_shorthand="$2" ;;
|
||||
--ip_host) public_ip_host="$2" ;;
|
||||
--birthday_shorthand) birthday_shorthand="$2" ;;
|
||||
--birthday_time) birthday_time="$2" ;;
|
||||
--disable)
|
||||
@@ -2216,7 +2448,12 @@ while [ "$1" ]; do
|
||||
done
|
||||
ascii_colors+=(7 7 7 7 7 7)
|
||||
;;
|
||||
--ascii_distro) ascii_distro="$2" ;;
|
||||
|
||||
--ascii_distro)
|
||||
image="ascii"
|
||||
ascii_distro="$2"
|
||||
case "$2" in "--"* | "") ascii_distro="$distro" ;; esac
|
||||
;;
|
||||
|
||||
# Screenshot
|
||||
--scrot | -s) scrot="on"; [ "$2" ] && scrot_path="$2" ;;
|
||||
@@ -2229,7 +2466,7 @@ while [ "$1" ]; do
|
||||
--stdout)
|
||||
case "$2" in
|
||||
"--"* | "") stdout="on" ;;
|
||||
*) stdout="on"; stdout_args="on"; args=("$@"); stdout ;;
|
||||
*) stdout="on"; args=("$@"); stdout ;;
|
||||
esac
|
||||
|
||||
unset info_color colors
|
||||
@@ -2329,4 +2566,3 @@ fi
|
||||
|
||||
# }}}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user