mirror of
https://github.com/dylanaraps/neofetch.git
synced 2025-12-21 19:27:12 +00:00
Compare commits
150 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8572cf9a08 | ||
|
|
abaf8808fe | ||
|
|
7646a76d02 | ||
|
|
4718dedd31 | ||
|
|
993d95d6bd | ||
|
|
3242425c4f | ||
|
|
55420c3c30 | ||
|
|
def8123c46 | ||
|
|
fe3da7e0b8 | ||
|
|
28f5630b05 | ||
|
|
38b705dd59 | ||
|
|
3025c2a8c4 | ||
|
|
efd48587c3 | ||
|
|
c48f201a9d | ||
|
|
901d5319bc | ||
|
|
874a29e0c3 | ||
|
|
05503e3914 | ||
|
|
c8b7ed6d1b | ||
|
|
b0cd5f07ec | ||
|
|
781a0fff9b | ||
|
|
74e8facfe2 | ||
|
|
04cf863f78 | ||
|
|
a1d87ea105 | ||
|
|
eeaae2d554 | ||
|
|
0b3fe3301f | ||
|
|
1948f0e4ff | ||
|
|
72e4e35b28 | ||
|
|
e506315bac | ||
|
|
9c48d2548a | ||
|
|
23f0e9d200 | ||
|
|
eda671d732 | ||
|
|
f24432a63a | ||
|
|
36203d1919 | ||
|
|
e021d30d1e | ||
|
|
832c7bbd81 | ||
|
|
e4e4594aef | ||
|
|
6b926485f1 | ||
|
|
87927bc81b | ||
|
|
11c8c289a8 | ||
|
|
f5e55acc67 | ||
|
|
17d334e44f | ||
|
|
83a0781a3f | ||
|
|
b8bcd13346 | ||
|
|
d55ff4ee94 | ||
|
|
a76d3285b2 | ||
|
|
d23a071fc0 | ||
|
|
2094c134ce | ||
|
|
ea580434aa | ||
|
|
28adc60e57 | ||
|
|
d8e1150e19 | ||
|
|
9902609679 | ||
|
|
5cca832de5 | ||
|
|
15451a5283 | ||
|
|
0180485851 | ||
|
|
8deb31b3d6 | ||
|
|
6a3845486b | ||
|
|
0573560cca | ||
|
|
65fb501c1f | ||
|
|
0e50e7d3ba | ||
|
|
0efc00419e | ||
|
|
ea55959468 | ||
|
|
cedc3846d1 | ||
|
|
efa8110d31 | ||
|
|
1216c9d5ad | ||
|
|
d23dcbe3bc | ||
|
|
e6044b3c41 | ||
|
|
d742d9aa9c | ||
|
|
e562e73387 | ||
|
|
f8f26453ae | ||
|
|
b37916e42a | ||
|
|
631ae8d2b4 | ||
|
|
a6573119f9 | ||
|
|
1e6804f54a | ||
|
|
4659863737 | ||
|
|
d34f01f21b | ||
|
|
464a810f94 | ||
|
|
1e9c22af9f | ||
|
|
a575c01b5c | ||
|
|
e1f2dcac93 | ||
|
|
012e2cbcb1 | ||
|
|
48e1cd5132 | ||
|
|
e92a03816e | ||
|
|
7f732aef1e | ||
|
|
fc06ad86cf | ||
|
|
adeb59173d | ||
|
|
bfcab94391 | ||
|
|
18143b4be2 | ||
|
|
6803b571b7 | ||
|
|
0c4d4eb23a | ||
|
|
1bd185874c | ||
|
|
91a7bd4737 | ||
|
|
7cf891a63b | ||
|
|
fd3d2fc29b | ||
|
|
f7614f5703 | ||
|
|
ce7ef19372 | ||
|
|
7bf8f17854 | ||
|
|
9b0c8fff2c | ||
|
|
ac7cf27147 | ||
|
|
30a6d8641b | ||
|
|
d8561cceed | ||
|
|
8d250e41ba | ||
|
|
8c783d63a2 | ||
|
|
53eafeb414 | ||
|
|
1a6fe2099c | ||
|
|
93bfcf178a | ||
|
|
707601bbf7 | ||
|
|
98061ca6c0 | ||
|
|
0c03845100 | ||
|
|
569bef567f | ||
|
|
24283be05d | ||
|
|
e8bdd31b46 | ||
|
|
c9d14c2dbe | ||
|
|
38641c690e | ||
|
|
d1e81f3344 | ||
|
|
3cf7c5ffa2 | ||
|
|
e2d1cb27a5 | ||
|
|
eec7f08eee | ||
|
|
4387233378 | ||
|
|
e9c8e6c2a3 | ||
|
|
072ad5cfff | ||
|
|
982f2b59ec | ||
|
|
1af650eaf1 | ||
|
|
39986f2197 | ||
|
|
716e50ecbf | ||
|
|
51fa1b3c12 | ||
|
|
ceadf7d5fa | ||
|
|
6c8d8f2cc6 | ||
|
|
9becea4feb | ||
|
|
153c26aa1f | ||
|
|
110e95a194 | ||
|
|
07ade10735 | ||
|
|
0dea3ba495 | ||
|
|
8c3fef5396 | ||
|
|
c583d06780 | ||
|
|
953979937f | ||
|
|
7afd5b2d22 | ||
|
|
b952030011 | ||
|
|
fefad4f98c | ||
|
|
199dadd537 | ||
|
|
0af39a6d30 | ||
|
|
ca54e76f52 | ||
|
|
2b2a9c19dc | ||
|
|
69046ae124 | ||
|
|
04d180c6f0 | ||
|
|
43132fc4e5 | ||
|
|
6ee9464101 | ||
|
|
bff259fdd0 | ||
|
|
b4e5169aa9 | ||
|
|
8fb4aec1ed | ||
|
|
e44a06aa2c |
89
CHANGELOG.md
89
CHANGELOG.md
@@ -1,88 +1,41 @@
|
|||||||
This minor release fixes all of the bugs that were found in the 3.0 release.
|
|
||||||
|
|
||||||
Thanks for all of the bug reports and contributions. :)
|
|
||||||
|
|
||||||
|
|
||||||
## Contributors
|
## Contributors
|
||||||
|
|
||||||
- **[@SomaUlte](https://github.com/SomaUlte)**
|
- **[@MatthewCox](https://github.com/MatthewCox)**
|
||||||
- **[@jorgegonzalez](https://github.com/jorgegonzalez)**
|
|
||||||
- **[@dawidd6](https://github.com/dawidd6)**
|
- **[@dawidd6](https://github.com/dawidd6)**
|
||||||
|
- **[@erikdubois](https://github.com/erikdubois)**
|
||||||
- **[@mstraube](https://github.com/mstraube)**
|
- **[@mstraube](https://github.com/mstraube)**
|
||||||
- **[@YellowApple](https://github.com/YellowApple)**
|
|
||||||
- **[@siiptuo](https://github.com/siiptuo)**
|
|
||||||
- **[@Head-on-a-Stick](https://github.com/Head-on-a-Stick)**
|
|
||||||
- **[@konimex](https://github.com/konimex)**
|
|
||||||
|
|
||||||
|
|
||||||
## Operating System
|
|
||||||
|
|
||||||
- Added support for ArchBox Linux.
|
|
||||||
|
|
||||||
|
|
||||||
## General
|
## General
|
||||||
|
|
||||||
- Fixed output if subtitles are disabled and `prin` is used in an info function.
|
- Minimum required BASH version is now 3.2.
|
||||||
- Fixed underlines not working when used with `prin`.
|
- (Neofetch has always used 3.2+ features, I've just made it obvious now in the documentation.)
|
||||||
- Fixed HAIKU install path. **[@YellowApple](https://github.com/YellowApple)**
|
|
||||||
|
|
||||||
|
|
||||||
## Config
|
|
||||||
|
|
||||||
- Fixed default config not found.
|
|
||||||
- Don't set locale in config file.
|
|
||||||
|
|
||||||
|
|
||||||
## Info
|
|
||||||
|
|
||||||
**Memory**<br \>
|
|
||||||
|
|
||||||
- Changed memory label to `MiB` on OS that output memory in Mebibytes.
|
|
||||||
|
|
||||||
**Shell**<br \>
|
|
||||||
|
|
||||||
- Fixed a crash when the user has `bash 3` installed.
|
|
||||||
|
|
||||||
**Packages**<br \>
|
|
||||||
|
|
||||||
- Added support for Chromebrew.
|
|
||||||
|
|
||||||
**GPU**<br \>
|
|
||||||
|
|
||||||
- [Linux] Display detailed information about Intel GPUs. **[@SomaUlte](https://github.com/SomaUlte)**
|
|
||||||
|
|
||||||
**Color Blocks**<br \>
|
|
||||||
|
|
||||||
- Fixed issue with `color_blocks="off"` adding an extra newline to the output.
|
|
||||||
|
|
||||||
**Song**<br \>
|
|
||||||
|
|
||||||
- Don't print `$song` if it's empty and `song_shorthand` is on. **[@mstraube](https://github.com/mstraube)**
|
|
||||||
- Fixed `mpd` detection when `mpd` is on a different host. **[@dawidd6](https://github.com/dawidd6)**
|
|
||||||
- Use `get_song_dbus` for Audacious. **[@mstraube](https://github.com/mstraube)**
|
|
||||||
|
|
||||||
**Terminal Font**<br \>
|
|
||||||
|
|
||||||
- [Alacritty] Fixed font detection. **[@siiptuo](https://github.com/siiptuo)**
|
|
||||||
|
|
||||||
|
|
||||||
## Images
|
## Images
|
||||||
|
|
||||||
- [iTerm2] Fixed issue with line-breaks printing spaces over the image. **[@jorgegonzalez](https://github.com/jorgegonzalez)**
|
- [w3m] Added `--loop` flag which makes Neofetch draw the image once per second.
|
||||||
- Fixed issue with images not working in Terminology.
|
- This is a workaround to the images disappearing on resize and workspace switch.
|
||||||
- Fixed issue when `image_source` was set to `wall`.
|
- Use Ctrl+C to exit.
|
||||||
- [w3m-img] Fixed issues with `w3m-img` and `tmux`.
|
|
||||||
|
|
||||||
|
|
||||||
## Ascii
|
## Ascii
|
||||||
|
|
||||||
- [Windows 10] Fixed `ascii_distro` not working.
|
- Added Ubuntu-MATE ascii art.
|
||||||
- Fixed a bug where the backend is `ascii` but the image_source is an image file.
|
- Fixed ArchLabs ascii art. **[@erikdubois](https://github.com/erikdubois)**
|
||||||
- Fixed custom ascii files not working.
|
|
||||||
- Removed extra backslashes from OpenBSD ascii art. **[@Head-on-a-Stick](https://github.com/Head-on-a-Stick)**
|
|
||||||
|
|
||||||
|
|
||||||
## Scrot
|
## Info
|
||||||
|
|
||||||
- Added message to let users know that a screenshot was taken.
|
**Terminal Emulator**
|
||||||
|
|
||||||
|
- Added font support for mate-terminal. **[@mstraube](https://github.com/mstraube)**
|
||||||
|
- [Termite] Fix font mismatch. **[@MatthewCox](https://github.com/MatthewCox)**
|
||||||
|
|
||||||
|
**GPU**
|
||||||
|
|
||||||
|
- [Linux] Fixed GPU sort.
|
||||||
|
|
||||||
|
**Song**
|
||||||
|
|
||||||
|
- Do not detect ibus\* or indicator\* as player. **[@dawidd6](https://github.com/dawidd6)**
|
||||||
|
|||||||
12
README.md
12
README.md
@@ -6,11 +6,11 @@
|
|||||||
[](./LICENSE.md)
|
[](./LICENSE.md)
|
||||||
[](https://github.com/dylanaraps/neofetch/releases)
|
[](https://github.com/dylanaraps/neofetch/releases)
|
||||||
|
|
||||||
Neofetch is a CLI system information tool written in BASH. Neofetch displays information about your system next to an image, your OS logo, or any ascii file of your choice. The main purpose of Neofetch is to be used in screenshots to show other users what OS/Distro you're running, what Theme/Icons you're using and etc.
|
Neofetch is a CLI system information tool written in BASH. Neofetch displays information about your system next to an image, your OS logo, or any ASCII file of your choice. The main purpose of Neofetch is to be used in screenshots to show other users what OS/Distro you're running, what Theme/Icons you're using etc.
|
||||||
|
|
||||||
Neofetch is highly customizable through the use of commandline flags or the user config file. There are over 50 config options to mess around with and there's the `print_info()` function and friends which let you add your own custom info.
|
Neofetch is highly customizable through the use of command line flags or the user config file. There are over 50 config options to mess around with and there's the `print_info()` function and friends which let you add your own custom info.
|
||||||
|
|
||||||
Neofetch can be used on any OS that has BASH, it's just a matter of adding support. If your OS/Distro isn't in the list below, feel free to open an issue on the repo and I'll gladly add support. Neofetch currently supports `Linux`, `MacOS`, `iOS`, `BSD`, `Solaris`, `Android`, `Haiku`, `GNU Hurd`, `MINIX`, `AIX`, and `Windows (Cygwin/MSYS2/Windows 10 Linux subsystem)`.
|
Neofetch can be used on any OS that has BASH 3.2+, it's just a matter of adding support. If your OS/Distro isn't in the list below, feel free to open an issue on the repo and I'll gladly add support. Neofetch currently supports `Linux`, `MacOS`, `iOS`, `BSD`, `Solaris`, `Android`, `Haiku`, `GNU Hurd`, `MINIX`, `AIX`, and `Windows (Cygwin/MSYS2/MinGW/Windows 10 Linux subsystem)`.
|
||||||
|
|
||||||
For more information:
|
For more information:
|
||||||
|
|
||||||
@@ -48,7 +48,7 @@ https://github.com/dylanaraps/neofetch/wiki/Customizing-Info
|
|||||||
|
|
||||||
### Customizing the script using a custom alias
|
### Customizing the script using a custom alias
|
||||||
|
|
||||||
If you don't want to use the config file you can customize almost everything using launch flags!
|
If you don't want to use the config file you can customize almost everything using launch flags.
|
||||||
|
|
||||||
Here's an example neofetch alias:
|
Here's an example neofetch alias:
|
||||||
|
|
||||||
@@ -76,6 +76,6 @@ Thanks to:
|
|||||||
- Thanks for using Neofetch!
|
- Thanks for using Neofetch!
|
||||||
- [Screenfetch](https://github.com/KittyKatt/screenFetch):
|
- [Screenfetch](https://github.com/KittyKatt/screenFetch):
|
||||||
- We've used some snippets as a base for a few functions in this script.
|
- We've used some snippets as a base for a few functions in this script.
|
||||||
- Some of the ascii logos.
|
- Some of the ASCII logos.
|
||||||
- [ufetch](https://github.com/jschx/ufetch):
|
- [ufetch](https://github.com/jschx/ufetch):
|
||||||
- Tiny ascii logos
|
- Tiny ASCII logos
|
||||||
|
|||||||
18
ascii/distro/archlabs
Normal file
18
ascii/distro/archlabs
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
${c1} sy
|
||||||
|
h--d
|
||||||
|
d---:
|
||||||
|
:----/N
|
||||||
|
:------/N
|
||||||
|
N/----:---+
|
||||||
|
N/---+/ :--:o
|
||||||
|
N/--:/ ::::s
|
||||||
|
+--- ::::s
|
||||||
|
N+---+ ::::s
|
||||||
|
N+----o +:o s::::s
|
||||||
|
N/----:: s:::s h:::::s
|
||||||
|
N/----:::y::::+ o::::::o
|
||||||
|
N/---::::::::::s d::::::::+N
|
||||||
|
/--::::::::::::dd::::::::::+N
|
||||||
|
:-:::/+syhd NNN N dhys+/:::/
|
||||||
|
d::+ydN /s+/d
|
||||||
|
arc y\\.
|
||||||
16
ascii/distro/desaos
Normal file
16
ascii/distro/desaos
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
${c1}███████████████████████
|
||||||
|
███████████████████████
|
||||||
|
███████████████████████
|
||||||
|
███████████████████████
|
||||||
|
████████ ███████
|
||||||
|
████████ ███████
|
||||||
|
████████ ███████
|
||||||
|
████████ ███████
|
||||||
|
████████ ███████
|
||||||
|
████████ ███████
|
||||||
|
████████ ███████
|
||||||
|
██████████████████████████████
|
||||||
|
██████████████████████████████
|
||||||
|
████████████████████████
|
||||||
|
████████████████████████
|
||||||
|
████████████████████████
|
||||||
18
ascii/distro/nitrux
Normal file
18
ascii/distro/nitrux
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
${c1}`:/.
|
||||||
|
`/yo
|
||||||
|
`/yo
|
||||||
|
`/yo .+:.
|
||||||
|
`/yo .sys+:.`
|
||||||
|
`/yo `-/sys+:.`
|
||||||
|
`/yo ./sss+:.`
|
||||||
|
`/yo .:oss+:-`
|
||||||
|
`/yo ./o///:-`
|
||||||
|
`/yo `.-:///////:`
|
||||||
|
`/yo `.://///++//-``
|
||||||
|
`/yo `.-:////++++/-`
|
||||||
|
`/yo `-://///++o+/-`
|
||||||
|
`/yo `-/+o+++ooo+/-`
|
||||||
|
`/s+:+oooossso/.`
|
||||||
|
`//+sssssso:.
|
||||||
|
`+syyyy+:`
|
||||||
|
:+s+-
|
||||||
18
ascii/distro/obrevenge
Normal file
18
ascii/distro/obrevenge
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
${c1} __ __
|
||||||
|
_@@@@ @@@g_
|
||||||
|
_@@@@@@ @@@@@@
|
||||||
|
_@@@@@@M W@@@@@@_
|
||||||
|
j@@@@P ^W@@@@
|
||||||
|
@@@@L____ _____Q@@@@
|
||||||
|
Q@@@@@@@@@@j@@@@@@@@@@
|
||||||
|
@@@@@ T@j@ T@@@@@
|
||||||
|
@@@@@ ___Q@J@ _@@@@@
|
||||||
|
@@@@@fMMM@@j@jggg@@@@@@
|
||||||
|
@@@@@ j@j@^MW@P @@@@
|
||||||
|
Q@@@@@ggg@@f@ @@@@@@L
|
||||||
|
^@@@@WWMMP ^ Q@@@@
|
||||||
|
@@@@@_ _@@@@l
|
||||||
|
W@@@@@g_____g@@@@@P
|
||||||
|
@@@@@@@@@@@@@@@@l
|
||||||
|
^W@@@@@@@@@@@P
|
||||||
|
^TMMMMTll
|
||||||
@@ -1,17 +1,16 @@
|
|||||||
${c1} eeeeeeeee
|
${c1} `.-. `.
|
||||||
eeeeeeeeeeeeeee
|
`.` `:++. `-+o+.
|
||||||
eeeeee${c2}//////////${c1}eeeee
|
`` `:+/. `:+/. `-+oooo+
|
||||||
eeeee${c2}///////////////${c1}eeeee
|
``-::-.:+/. `:+/. `-+oooooo+
|
||||||
eeeee${c2}/// ////${c1}eeee
|
`.-:///- ..` .-. `-+oooooooo-
|
||||||
eeee${c2}// ///${c1}eeeee
|
`..-..` `+ooooooooo:
|
||||||
eee ${c2}///${c1}eeeee
|
`` :oooooooo/
|
||||||
ee ${c2}//${c1}eeeeee
|
`ooooooo:
|
||||||
e ${c2}/${c1}eeeeeee
|
`oooooo:
|
||||||
eeeeeee
|
-oooo+.
|
||||||
eeeeee
|
+ooo/`
|
||||||
eeeeee
|
-ooo-
|
||||||
eeeee
|
`+o/.
|
||||||
eeee
|
/+-
|
||||||
eee
|
//`
|
||||||
ee
|
-.
|
||||||
e
|
|
||||||
|
|||||||
@@ -1,18 +1,23 @@
|
|||||||
${c1} .',;:cc;,'. .,;::c:,,.
|
${c1} `.::///+:/-. --///+//-:``
|
||||||
,ooolcloooo: 'oooooccloo:
|
`+oooooooooooo: `+oooooooooooo:
|
||||||
.looooc;;:ol :oc;;:ooooo'
|
/oooo++//ooooo: ooooo+//+ooooo.
|
||||||
;oooooo: ,ooooooc.
|
`+ooooooo:-:oo- +o+::/ooooooo:
|
||||||
.,:;'. .;:;'.
|
`:oooooooo+`` `.oooooooo+-
|
||||||
${c2}.... ..'''''. ....
|
`:++ooo/. :+ooo+/.`
|
||||||
.''. ..'''''. ..''.
|
${c2}...` `.----.` ``..
|
||||||
.. ..... ..... ..
|
.::::-``:::::::::.`-:::-`
|
||||||
. .''''''' .''''''. .
|
-:::-` .:::::::-` `-:::-
|
||||||
.'' .'''''''' .'''''''. ''.
|
`::. `.--.` `` `.---.``.::`
|
||||||
''' ''''''' .'''''' '''
|
.::::::::` -::::::::` `
|
||||||
.' ........... ... .'.
|
.::` .:::::::::- `::::::::::``::.
|
||||||
.... ''''''''. .''.
|
-:::` ::::::::::. ::::::::::.`:::-
|
||||||
'''''. ''''''''. .'''''
|
:::: -::::::::. `-:::::::: ::::
|
||||||
'''''. .'''''. .'''''.
|
-::- .-:::-.``....``.-::-. -::-
|
||||||
..''. . .''..
|
.. `` .::::::::. `..`..
|
||||||
.'''''''
|
-:::-` -::::::::::` .:::::`
|
||||||
......
|
:::::::` -::::::::::` :::::::.
|
||||||
|
.::::::: -::::::::. ::::::::
|
||||||
|
`-:::::` ..--.` ::::::.
|
||||||
|
`...` `...--..` `...`
|
||||||
|
.::::::::::
|
||||||
|
`.-::::-`
|
||||||
|
|||||||
17
ascii/distro/slitaz
Normal file
17
ascii/distro/slitaz
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
${c1} @ @( @
|
||||||
|
@@ @@ @ @/
|
||||||
|
@@ @@ @@ @@
|
||||||
|
@@ %@@ @@ @@
|
||||||
|
@@ %@@@ @@@@@. @@@@ @@
|
||||||
|
@@@ @@@@ @@@@@@@ &@@@ @@@
|
||||||
|
@@@@@@@ %@@@@@@@@@@@@ &@@@% @@@@@@@/
|
||||||
|
,@@@@@@@@@@@@@@@@@@@@@@@@@
|
||||||
|
.@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/
|
||||||
|
@@@@@@. @@@@@@@@@@@@@@@@@@@@@ /@@@@@@
|
||||||
|
@@ @@@@@ @@@@@@@@@@@@, @@@@@ @@@
|
||||||
|
@@ @@@@. @@@@@@@@@@@@@% #@@@@ @@.
|
||||||
|
@@ ,@@ @@@@@@@@@@@@@ @@@ @@
|
||||||
|
@ @@. @@@@@@@@@@@@@ @@@ *@
|
||||||
|
@ @@ @@@@@@@@@@@@ @@ @
|
||||||
|
@ @@@@@@@@@. #@
|
||||||
|
@ ,@@@@@ @
|
||||||
20
ascii/distro/ubuntu-mate
Normal file
20
ascii/distro/ubuntu-mate
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
${c1} `:+shmNNMMNNmhs+:`
|
||||||
|
.odMMMMMMMMMMMMMMMMMMdo.
|
||||||
|
/dMMMMMMMMMMMMMMMmMMMMMMMMd/
|
||||||
|
:mMMMMMMMMMMMMNNNNM/`/yNMMMMMMm:
|
||||||
|
`yMMMMMMMMMms:..-::oM: -omMMMMMy`
|
||||||
|
`dMMMMMMMMy-.odNMMMMMM: -odMMMMMMd`
|
||||||
|
hMMMMMMMm-.hMMy/....+M:`/yNm+mMMMMMMMh
|
||||||
|
/MMMMNmMN-:NMy`-yNMMMMMmNyyMN:`dMMMMMMM/
|
||||||
|
hMMMMm -odMMh`sMMMMMMMMMMs sMN..MMMMMMMh
|
||||||
|
NMMMMm `/yNMMMMMMMMMMMM: MM+ mMMMMMMN
|
||||||
|
NMMMMm `/yNMMMMMMMMMMMM: MM+ mMMMMMMN
|
||||||
|
hMMMMm -odMMh sMMMMMMMMMMs oMN..MMMMMMMh
|
||||||
|
/MMMMNNMN-:NMy`-yNMMMMMNNsyMN:`dMMMMMMM/
|
||||||
|
hMMMMMMMm-.hMMy/....+M:.+hNd+mMMMMMMMh
|
||||||
|
`dMMMMMMMMy-.odNMMMMMM: :smMMMMMMd`
|
||||||
|
yMMMMMMMMMms/..-::oM: .+dMMMMMy
|
||||||
|
:mMMMMMMMMMMMMNNNNM: :smMMMMMMm:
|
||||||
|
/dMMMMMMMMMMMMMMMdNMMMMMMMd/
|
||||||
|
.odMMMMMMMMMMMMMMMMMMdo.
|
||||||
|
`:+shmNNMMNNmhs+:`
|
||||||
@@ -37,6 +37,7 @@ print_info() {
|
|||||||
# info "Public IP" public_ip
|
# info "Public IP" public_ip
|
||||||
# info "Users" users
|
# info "Users" users
|
||||||
# info "Install Date" install_date
|
# info "Install Date" install_date
|
||||||
|
# info "Locale" locale # This only works on glibc systems.
|
||||||
|
|
||||||
info line_break
|
info line_break
|
||||||
info cols
|
info cols
|
||||||
@@ -138,6 +139,17 @@ shell_version="on"
|
|||||||
# NOTE: Any file in '/sys/devices/system/cpu/cpu0/cpufreq' can be used as a value.
|
# NOTE: Any file in '/sys/devices/system/cpu/cpu0/cpufreq' can be used as a value.
|
||||||
speed_type="bios_limit"
|
speed_type="bios_limit"
|
||||||
|
|
||||||
|
# CPU speed shorthand
|
||||||
|
#
|
||||||
|
# Default: 'off'
|
||||||
|
# Values: 'on', 'off'.
|
||||||
|
# Flag: --speed_shorthand.
|
||||||
|
#
|
||||||
|
# Example:
|
||||||
|
# on: 'i7-6500U (4) @ 3.1GHz'
|
||||||
|
# off: 'i7-6500U (4) @ 3.100GHz'
|
||||||
|
speed_shorthand="off"
|
||||||
|
|
||||||
# Shorten the output of the CPU function
|
# Shorten the output of the CPU function
|
||||||
#
|
#
|
||||||
# Default: 'off'
|
# Default: 'off'
|
||||||
@@ -317,7 +329,7 @@ disk_show=('/')
|
|||||||
# What to append to the Disk subtitle.
|
# What to append to the Disk subtitle.
|
||||||
#
|
#
|
||||||
# Default: 'mount'
|
# Default: 'mount'
|
||||||
# Values: 'mount', 'name'
|
# Values: 'mount', 'name', 'dir'
|
||||||
# Flag: --disk_subtitle
|
# Flag: --disk_subtitle
|
||||||
#
|
#
|
||||||
# Example:
|
# Example:
|
||||||
@@ -326,6 +338,11 @@ disk_show=('/')
|
|||||||
#
|
#
|
||||||
# mount: 'Disk (/): 74G / 118G (66%)'
|
# mount: 'Disk (/): 74G / 118G (66%)'
|
||||||
# 'Disk (/mnt/Local Disk): 74G / 118G (66%)'
|
# 'Disk (/mnt/Local Disk): 74G / 118G (66%)'
|
||||||
|
# 'Disk (/mnt/Videos): 74G / 118G (66%)'
|
||||||
|
#
|
||||||
|
# dir: 'Disk (/): 74G / 118G (66%)'
|
||||||
|
# 'Disk (Local Disk): 74G / 118G (66%)'
|
||||||
|
# 'Disk (Videos): 74G / 118G (66%)'
|
||||||
disk_subtitle="mount"
|
disk_subtitle="mount"
|
||||||
|
|
||||||
|
|
||||||
@@ -523,6 +540,7 @@ disk_display="off"
|
|||||||
|
|
||||||
# Backend Settings
|
# Backend Settings
|
||||||
|
|
||||||
|
|
||||||
# Image backend.
|
# Image backend.
|
||||||
#
|
#
|
||||||
# Default: 'ascii'
|
# Default: 'ascii'
|
||||||
@@ -585,6 +603,15 @@ ascii_bold="on"
|
|||||||
# Image Options
|
# Image Options
|
||||||
|
|
||||||
|
|
||||||
|
# Image loop
|
||||||
|
# Setting this to on will make neofetch redraw the image constantly until
|
||||||
|
# Ctrl+C is pressed. This fixes display issues in some terminal emulators.
|
||||||
|
#
|
||||||
|
# Default: 'off'
|
||||||
|
# Values: 'on', 'off'
|
||||||
|
# Flag: --loop
|
||||||
|
image_loop="off"
|
||||||
|
|
||||||
# Thumbnail directory
|
# Thumbnail directory
|
||||||
#
|
#
|
||||||
# Default: '~/.cache/thumbnails/neofetch'
|
# Default: '~/.cache/thumbnails/neofetch'
|
||||||
@@ -670,16 +697,6 @@ scrot="off"
|
|||||||
# Flag: --scrot_cmd
|
# Flag: --scrot_cmd
|
||||||
scrot_cmd="auto"
|
scrot_cmd="auto"
|
||||||
|
|
||||||
# Screenshot Directory
|
|
||||||
# Where to save the screenshots
|
|
||||||
#
|
|
||||||
# Default: '~/Pictures/'
|
|
||||||
# Values: 'dir'
|
|
||||||
# Flag: --scrot_dir
|
|
||||||
#
|
|
||||||
# Note: Neofetch won't create the directory if it doesn't exist.
|
|
||||||
scrot_dir="$HOME/Pictures/"
|
|
||||||
|
|
||||||
# Screenshot Filename
|
# Screenshot Filename
|
||||||
# What to name the screenshots
|
# What to name the screenshots
|
||||||
#
|
#
|
||||||
@@ -707,4 +724,4 @@ image_host="teknik"
|
|||||||
#
|
#
|
||||||
# NOTE: Don't change this value, neofetch reads this to determine
|
# NOTE: Don't change this value, neofetch reads this to determine
|
||||||
# how to handle backwards compatibility.
|
# how to handle backwards compatibility.
|
||||||
config_version="3.0.1"
|
config_version="3.1.0-git"
|
||||||
|
|||||||
424
neofetch
424
neofetch
@@ -9,7 +9,7 @@
|
|||||||
# https://github.com/dylanaraps/
|
# https://github.com/dylanaraps/
|
||||||
|
|
||||||
# Neofetch version.
|
# Neofetch version.
|
||||||
version="3.0.1"
|
version="3.1.0-git"
|
||||||
|
|
||||||
bash_version="${BASH_VERSION/.*}"
|
bash_version="${BASH_VERSION/.*}"
|
||||||
sys_locale="${LANG:-C}"
|
sys_locale="${LANG:-C}"
|
||||||
@@ -38,7 +38,7 @@ get_os() {
|
|||||||
"Linux" | "GNU"*) os="Linux" ;;
|
"Linux" | "GNU"*) os="Linux" ;;
|
||||||
"Darwin") os="$(sw_vers -productName)" ;;
|
"Darwin") os="$(sw_vers -productName)" ;;
|
||||||
*"BSD" | "DragonFly" | "Bitrig") os="BSD" ;;
|
*"BSD" | "DragonFly" | "Bitrig") os="BSD" ;;
|
||||||
"CYGWIN"* | "MSYS"*) os="Windows" ;;
|
"CYGWIN"* | "MSYS"* | "MINGW"*) os="Windows" ;;
|
||||||
"SunOS") os="Solaris" ;;
|
"SunOS") os="Solaris" ;;
|
||||||
"Haiku") os="Haiku" ;;
|
"Haiku") os="Haiku" ;;
|
||||||
"MINIX") os="MINIX" ;;
|
"MINIX") os="MINIX" ;;
|
||||||
@@ -63,6 +63,13 @@ get_distro() {
|
|||||||
*) distro="$(lsb_release -sd) on Windows 10" ;;
|
*) distro="$(lsb_release -sd) on Windows 10" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
elif [[ "$(< /proc/version)" == *"cros"* || -f "/dev/cros_ec" ]]; then
|
||||||
|
case "$distro_shorthand" in
|
||||||
|
"on") distro="$(lsb_release -sir) [Chrome OS]" ;;
|
||||||
|
"tiny") distro="Chrome OS" ;;
|
||||||
|
*) distro="$(lsb_release -sd) on Chrome OS" ;;
|
||||||
|
esac
|
||||||
|
|
||||||
elif [[ -f "/etc/GoboLinuxVersion" ]]; then
|
elif [[ -f "/etc/GoboLinuxVersion" ]]; then
|
||||||
case "$distro_shorthand" in
|
case "$distro_shorthand" in
|
||||||
"on" | "tiny") distro="GoboLinux" ;;
|
"on" | "tiny") distro="GoboLinux" ;;
|
||||||
@@ -93,6 +100,9 @@ get_distro() {
|
|||||||
"tiny") distro="${distro//version*}" ;;
|
"tiny") distro="${distro//version*}" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
elif type -p tazpkg >/dev/null; then
|
||||||
|
distro="SliTaz $(< /etc/slitaz-release)"
|
||||||
|
|
||||||
elif [[ -d "/system/app/" && -d "/system/priv-app" ]]; then
|
elif [[ -d "/system/app/" && -d "/system/priv-app" ]]; then
|
||||||
distro="Android $(getprop ro.build.version.release)"
|
distro="Android $(getprop ro.build.version.release)"
|
||||||
|
|
||||||
@@ -468,7 +478,7 @@ get_packages() {
|
|||||||
packages="$((packages+=$(ls -d -1 /Programs/*/ | wc -l)))"
|
packages="$((packages+=$(ls -d -1 /Programs/*/ | wc -l)))"
|
||||||
|
|
||||||
type -p eopkg >/dev/null && \
|
type -p eopkg >/dev/null && \
|
||||||
packages="$((packages+=$(eopkg list-installed | wc -l)))"
|
packages="$((packages+=$(ls -1 /var/lib/eopkg/package | wc -l)))"
|
||||||
|
|
||||||
type -p pkg_info >/dev/null && \
|
type -p pkg_info >/dev/null && \
|
||||||
packages="$((packages+=$(pkg_info | wc -l)))"
|
packages="$((packages+=$(pkg_info | wc -l)))"
|
||||||
@@ -476,6 +486,9 @@ get_packages() {
|
|||||||
type -p crew >/dev/null && \
|
type -p crew >/dev/null && \
|
||||||
packages="$((packages+=$(ls -l /usr/local/etc/crew/meta/*.filelist | wc -l)))"
|
packages="$((packages+=$(ls -l /usr/local/etc/crew/meta/*.filelist | wc -l)))"
|
||||||
|
|
||||||
|
type -p tazpkg >/dev/null && \
|
||||||
|
packages="$((packages+=$(tazpkg list | wc -l) - 6))"
|
||||||
|
|
||||||
if type -p pkg >/dev/null; then
|
if type -p pkg >/dev/null; then
|
||||||
case "$kernel_name" in
|
case "$kernel_name" in
|
||||||
"FreeBSD") packages="$((packages+=$(pkg info | wc -l)))" ;;
|
"FreeBSD") packages="$((packages+=$(pkg info | wc -l)))" ;;
|
||||||
@@ -629,7 +642,17 @@ get_wm() {
|
|||||||
|
|
||||||
else
|
else
|
||||||
case "$os" in
|
case "$os" in
|
||||||
"Mac OS X") wm="Quartz Compositor" ;;
|
"Mac OS X")
|
||||||
|
ps_line="$(ps -e | grep -o '[S]pectacle\|[A]methyst\|[k]wm')"
|
||||||
|
|
||||||
|
case "$ps_line" in
|
||||||
|
*"kwm"*) wm="Kwm" ;;
|
||||||
|
*"Amethyst"*) wm="Amethyst" ;;
|
||||||
|
*"Spectacle"*) wm="Spectacle" ;;
|
||||||
|
*) wm="Quartz Compositor" ;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
|
||||||
"Windows")
|
"Windows")
|
||||||
wm="$(tasklist | grep -m 1 -o -F -e "bugn" -e "Windawesome" -e "blackbox" -e "emerge" -e "litestep")"
|
wm="$(tasklist | grep -m 1 -o -F -e "bugn" -e "Windawesome" -e "blackbox" -e "emerge" -e "litestep")"
|
||||||
[[ "$wm" == "blackbox" ]] && wm="bbLean (Blackbox)"
|
[[ "$wm" == "blackbox" ]] && wm="bbLean (Blackbox)"
|
||||||
@@ -805,11 +828,10 @@ get_cpu() {
|
|||||||
speed="$(< "${speed_dir}/bios_limit")" || \
|
speed="$(< "${speed_dir}/bios_limit")" || \
|
||||||
speed="$(< "${speed_dir}/scaling_max_freq")" || \
|
speed="$(< "${speed_dir}/scaling_max_freq")" || \
|
||||||
speed="$(< "${speed_dir}/cpuinfo_max_freq")"
|
speed="$(< "${speed_dir}/cpuinfo_max_freq")"
|
||||||
speed="$((speed / 100000))"
|
speed="$((speed / 1000))"
|
||||||
|
|
||||||
else
|
else
|
||||||
speed="$(awk -F ': |\\.' '/cpu MHz/ {printf $2; exit}' /proc/cpuinfo)"
|
speed="$(awk -F ': |\\.' '/cpu MHz/ {printf $2; exit}' /proc/cpuinfo)"
|
||||||
speed="$((speed / 100))"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Get CPU temp.
|
# Get CPU temp.
|
||||||
@@ -877,7 +899,6 @@ get_cpu() {
|
|||||||
# Get CPU speed.
|
# Get CPU speed.
|
||||||
speed="$(sysctl -n hw.cpuspeed)"
|
speed="$(sysctl -n hw.cpuspeed)"
|
||||||
[[ -z "$speed" ]] && speed="$(sysctl -n hw.clockrate)"
|
[[ -z "$speed" ]] && speed="$(sysctl -n hw.clockrate)"
|
||||||
speed="$((speed / 100))"
|
|
||||||
|
|
||||||
# Get CPU cores.
|
# Get CPU cores.
|
||||||
cores="$(sysctl -n hw.ncpu)"
|
cores="$(sysctl -n hw.ncpu)"
|
||||||
@@ -915,7 +936,6 @@ get_cpu() {
|
|||||||
|
|
||||||
# Get CPU speed.
|
# Get CPU speed.
|
||||||
speed="$(psrinfo -v | awk '/operates at/ {print $6; exit}')"
|
speed="$(psrinfo -v | awk '/operates at/ {print $6; exit}')"
|
||||||
speed="$((speed / 100))"
|
|
||||||
|
|
||||||
# Get CPU cores.
|
# Get CPU cores.
|
||||||
case "$cpu_cores" in
|
case "$cpu_cores" in
|
||||||
@@ -932,7 +952,6 @@ get_cpu() {
|
|||||||
# Get CPU speed.
|
# Get CPU speed.
|
||||||
speed="$(sysinfo -cpu | awk '/running at/ {print $NF; exit}')"
|
speed="$(sysinfo -cpu | awk '/running at/ {print $NF; exit}')"
|
||||||
speed="${speed/MHz}"
|
speed="${speed/MHz}"
|
||||||
speed="$((speed / 100))"
|
|
||||||
|
|
||||||
# Get CPU cores.
|
# Get CPU cores.
|
||||||
cores="$(sysinfo -cpu | grep -c -F 'CPU #')"
|
cores="$(sysinfo -cpu | grep -c -F 'CPU #')"
|
||||||
@@ -945,7 +964,6 @@ get_cpu() {
|
|||||||
# Get CPU speed.
|
# Get CPU speed.
|
||||||
speed="$(prtconf | awk -F':' '/Processor Clock Speed/ {printf $2}')"
|
speed="$(prtconf | awk -F':' '/Processor Clock Speed/ {printf $2}')"
|
||||||
speed="${speed/MHz}"
|
speed="${speed/MHz}"
|
||||||
speed="$((speed / 100))"
|
|
||||||
|
|
||||||
# Get CPU cores.
|
# Get CPU cores.
|
||||||
case "$cpu_cores" in
|
case "$cpu_cores" in
|
||||||
@@ -955,8 +973,12 @@ get_cpu() {
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
# Fix for speeds under 1ghz.
|
|
||||||
if [[ "$speed" ]]; then
|
if [[ "$speed" ]]; then
|
||||||
|
# Hide decimals if on.
|
||||||
|
[[ "$speed_shorthand" == "on" ]] && \
|
||||||
|
speed="$((speed / 100))"
|
||||||
|
|
||||||
|
# Fix for speeds under 1ghz.
|
||||||
if [[ -z "${speed:1}" ]]; then
|
if [[ -z "${speed:1}" ]]; then
|
||||||
speed="0.${speed}"
|
speed="0.${speed}"
|
||||||
else
|
else
|
||||||
@@ -1039,7 +1061,7 @@ get_cpu_usage() {
|
|||||||
case "$cpu_display" in
|
case "$cpu_display" in
|
||||||
"bar") cpu_usage="$(bar "$cpu_usage" 100)" ;;
|
"bar") cpu_usage="$(bar "$cpu_usage" 100)" ;;
|
||||||
"infobar") cpu_usage="${cpu_usage}% $(bar "$cpu_usage" 100)" ;;
|
"infobar") cpu_usage="${cpu_usage}% $(bar "$cpu_usage" 100)" ;;
|
||||||
"barinfo") cpu_usage="$(bar "$cpu_usage" 100) ${cpu_usage}%" ;;
|
"barinfo") cpu_usage="$(bar "$cpu_usage" 100)${info_color} ${cpu_usage}%" ;;
|
||||||
*) cpu_usage="${cpu_usage}%" ;;
|
*) cpu_usage="${cpu_usage}%" ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
@@ -1151,7 +1173,16 @@ get_gpu() {
|
|||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"BSD" | "Solaris" | "MINIX" | "AIX")
|
"Windows")
|
||||||
|
gpu="$(wmic path Win32_VideoController get caption)"
|
||||||
|
gpu="${gpu//Caption}"
|
||||||
|
;;
|
||||||
|
|
||||||
|
"Haiku")
|
||||||
|
gpu="$(listdev | grep -A2 -F 'device Display controller' | awk -F':' '/device beef/ {print $2}')"
|
||||||
|
;;
|
||||||
|
|
||||||
|
*)
|
||||||
case "$kernel_name" in
|
case "$kernel_name" in
|
||||||
"FreeBSD"* | "DragonFly"*)
|
"FreeBSD"* | "DragonFly"*)
|
||||||
gpu="$(pciconf -lv | grep -B 4 -F "VGA" | grep -F "device")"
|
gpu="$(pciconf -lv | grep -B 4 -F "VGA" | grep -F "device")"
|
||||||
@@ -1165,15 +1196,6 @@ get_gpu() {
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"Windows")
|
|
||||||
gpu="$(wmic path Win32_VideoController get caption)"
|
|
||||||
gpu="${gpu//Caption}"
|
|
||||||
;;
|
|
||||||
|
|
||||||
"Haiku")
|
|
||||||
gpu="$(listdev | grep -A2 -F 'device Display controller' | awk -F':' '/device beef/ {print $2}')"
|
|
||||||
;;
|
|
||||||
esac
|
esac
|
||||||
|
|
||||||
if [[ "$gpu_brand" == "off" ]]; then
|
if [[ "$gpu_brand" == "off" ]]; then
|
||||||
@@ -1263,13 +1285,13 @@ get_memory() {
|
|||||||
case "$memory_display" in
|
case "$memory_display" in
|
||||||
"bar") memory="$(bar "${mem_used}" "${mem_total}")" ;;
|
"bar") memory="$(bar "${mem_used}" "${mem_total}")" ;;
|
||||||
"infobar") memory="${memory} $(bar "${mem_used}" "${mem_total}")" ;;
|
"infobar") memory="${memory} $(bar "${mem_used}" "${mem_total}")" ;;
|
||||||
"barinfo") memory="$(bar "${mem_used}" "${mem_total}") ${memory}" ;;
|
"barinfo") memory="$(bar "${mem_used}" "${mem_total}")${info_color} ${memory}" ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
|
|
||||||
get_song() {
|
get_song() {
|
||||||
# This is absurdly long.
|
# This is absurdly long.
|
||||||
player="$(ps x | awk '!(/awk|Helper|Cache/) && /mpd|mopidy|cmus|mocp|spotify|Google Play|iTunes.app|rhythmbox|banshee|amarok|deadbeef|audacious|xmms2d|gnome-music|lollypop|clementine|pragha|exaile|juk|bluemindo|guayadeque|yarock|qmmp|quodlibet/ {printf $5 " " $6; exit}')"
|
player="$(ps x | awk '!(/ awk|Helper|Cache|ibus|indicator/) && /mpd|mopidy|cmus|mocp|spotify|Google Play|iTunes.app|rhythmbox|banshee|amarok|deadbeef|audacious|xmms2d|gnome-music|lollypop|clementine|pragha|exaile|juk|bluemindo|guayadeque|yarock|qmmp|quodlibet|deepin-music|tomahawk/ {printf $5 " " $6; exit}')"
|
||||||
|
|
||||||
get_song_dbus() {
|
get_song_dbus() {
|
||||||
# Multiple players use an almost identical dbus command to get the information.
|
# Multiple players use an almost identical dbus command to get the information.
|
||||||
@@ -1290,7 +1312,6 @@ get_song() {
|
|||||||
"deadbeef"*) song="$(deadbeef --nowplaying-tf '%artist% - %title%')" ;;
|
"deadbeef"*) song="$(deadbeef --nowplaying-tf '%artist% - %title%')" ;;
|
||||||
"xmms2d"*) song="$(xmms2 current -f '${artist} - ${title}')" ;;
|
"xmms2d"*) song="$(xmms2 current -f '${artist} - ${title}')" ;;
|
||||||
"qmmp"*) song="$(qmmp --nowplaying '%p - %t')" ;;
|
"qmmp"*) song="$(qmmp --nowplaying '%p - %t')" ;;
|
||||||
"audacious"*) get_song_dbus "audacious" ;;
|
|
||||||
"gnome-music"*) get_song_dbus "GnomeMusic" ;;
|
"gnome-music"*) get_song_dbus "GnomeMusic" ;;
|
||||||
"lollypop"*) get_song_dbus "Lollypop" ;;
|
"lollypop"*) get_song_dbus "Lollypop" ;;
|
||||||
"clementine"*) get_song_dbus "clementine" ;;
|
"clementine"*) get_song_dbus "clementine" ;;
|
||||||
@@ -1298,6 +1319,17 @@ get_song() {
|
|||||||
"bluemindo"*) get_song_dbus "Bluemindo" ;;
|
"bluemindo"*) get_song_dbus "Bluemindo" ;;
|
||||||
"guayadeque"*) get_song_dbus "guayadeque" ;;
|
"guayadeque"*) get_song_dbus "guayadeque" ;;
|
||||||
"yarock"*) get_song_dbus "yarock" ;;
|
"yarock"*) get_song_dbus "yarock" ;;
|
||||||
|
"deepin-music"*) get_song_dbus "deepinmusic" ;;
|
||||||
|
"tomahawk"*) get_song_dbus "tomahawk" ;;
|
||||||
|
|
||||||
|
"audacious"*)
|
||||||
|
song="$(audtool current-song)"
|
||||||
|
|
||||||
|
# Remove Album from 'Artist - Album - Title'
|
||||||
|
song="${song/-* -/-}"
|
||||||
|
|
||||||
|
[[ -z "$song" ]] && get_song_dbus "audacious"
|
||||||
|
;;
|
||||||
|
|
||||||
"cmus"*)
|
"cmus"*)
|
||||||
song="$(cmus-remote -Q | awk '/tag artist/ {$1=$2=""; print; print " - "} /tag title/ {$1=$2=""; print}')"
|
song="$(cmus-remote -Q | awk '/tag artist/ {$1=$2=""; print; print " - "} /tag title/ {$1=$2=""; print}')"
|
||||||
@@ -1362,23 +1394,9 @@ get_song() {
|
|||||||
|
|
||||||
get_resolution() {
|
get_resolution() {
|
||||||
case "$os" in
|
case "$os" in
|
||||||
"Linux" | "BSD" | "Solaris" | "MINIX" | "AIX")
|
|
||||||
if type -p xrandr >/dev/null; then
|
|
||||||
case "$refresh_rate" in
|
|
||||||
"on") resolution="$(xrandr --nograb --current | awk 'match($0,/[0-9]*\.[0-9]*\*/) {printf $1 " @ " substr($0,RSTART,RLENGTH) "Hz, "}')" ;;
|
|
||||||
"off") resolution="$(xrandr --nograb --current | awk '/\*/ {printf $1 ", "}')" ;;
|
|
||||||
esac
|
|
||||||
resolution="${resolution//\*}"
|
|
||||||
resolution="${resolution//\.[0-9][0-9]}"
|
|
||||||
|
|
||||||
elif type -p xdpyinfo >/dev/null; then
|
|
||||||
resolution="$(xdpyinfo | awk '/dimensions:/ {printf $2}')"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
|
|
||||||
"Mac OS X")
|
"Mac OS X")
|
||||||
if type -p screenresolution >/dev/null; then
|
if type -p screenresolution >/dev/null; then
|
||||||
resolution="$(screenresolution get | awk '/Display/ {printf $6 "Hz, "}')"
|
resolution="$(screenresolution get 2>&1 | awk '/Display/ {printf $6 "Hz, "}')"
|
||||||
resolution="${resolution//x??@/ @ }"
|
resolution="${resolution//x??@/ @ }"
|
||||||
|
|
||||||
else
|
else
|
||||||
@@ -1420,6 +1438,19 @@ get_resolution() {
|
|||||||
|
|
||||||
[[ "$refresh_rate" == "off" ]] && resolution="${resolution/ @*}"
|
[[ "$refresh_rate" == "off" ]] && resolution="${resolution/ @*}"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
*)
|
||||||
|
if type -p xrandr >/dev/null; then
|
||||||
|
case "$refresh_rate" in
|
||||||
|
"on") resolution="$(xrandr --nograb --current | awk 'match($0,/[0-9]*\.[0-9]*\*/) {printf $1 " @ " substr($0,RSTART,RLENGTH) "Hz, "}')" ;;
|
||||||
|
"off") resolution="$(xrandr --nograb --current | awk '/\*/ {printf $1 ", "}')" ;;
|
||||||
|
esac
|
||||||
|
resolution="${resolution//\*}"
|
||||||
|
|
||||||
|
elif type -p xdpyinfo >/dev/null; then
|
||||||
|
resolution="$(xdpyinfo | awk '/dimensions:/ {printf $2}')"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
resolution="${resolution%,*}"
|
resolution="${resolution%,*}"
|
||||||
@@ -1632,6 +1663,46 @@ get_term_font() {
|
|||||||
term_font="$(osascript -e 'tell application "Terminal" to font name of window frontmost')"
|
term_font="$(osascript -e 'tell application "Terminal" to font name of window frontmost')"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
"iTerm2")
|
||||||
|
# Unfortunately the profile name is not unique, but it seems to be the only thing
|
||||||
|
# that identifies an active profile. There is the "id of current session of current window"
|
||||||
|
# thou, but that does not match to a guid in the plist.
|
||||||
|
# So, be warned! Collisions may occur!
|
||||||
|
# See: https://groups.google.com/forum/#!topic/iterm2-discuss/0tO3xZ4Zlwg
|
||||||
|
local current_profile_name
|
||||||
|
current_profile_name="$(osascript -e 'tell application "iTerm2" to profile name of current session of current window')"
|
||||||
|
|
||||||
|
# Warning: Dynamic profiles are not taken into account here!
|
||||||
|
# https://www.iterm2.com/documentation-dynamic-profiles.html
|
||||||
|
|
||||||
|
# Count Guids in "New Bookmarks"; they should be unique
|
||||||
|
local profiles_count
|
||||||
|
profiles_count="$(/usr/libexec/PlistBuddy -c "Print :New\ Bookmarks:" ~/Library/Preferences/com.googlecode.iterm2.plist 2>/dev/null | grep -c "Guid")"
|
||||||
|
|
||||||
|
for ((i=0; i<=profiles_count; i++)); do
|
||||||
|
local profile_name
|
||||||
|
profile_name="$(/usr/libexec/PlistBuddy -c "Print :New\ Bookmarks:${i}:Name:" ~/Library/Preferences/com.googlecode.iterm2.plist 2>/dev/null)"
|
||||||
|
|
||||||
|
if [[ "$profile_name" == "$current_profile_name" ]]; then
|
||||||
|
# "Normal Font"
|
||||||
|
term_font="$(/usr/libexec/PlistBuddy -c "Print :New\ Bookmarks:${i}:Normal\ Font:" ~/Library/Preferences/com.googlecode.iterm2.plist)"
|
||||||
|
# Font for non-ascii characters
|
||||||
|
# Only check for a different non-ascii font, if the user checked
|
||||||
|
# the "use a different font for non-ascii text" switch.
|
||||||
|
local use_different_font
|
||||||
|
use_different_font="$(/usr/libexec/PlistBuddy -c "Print :New\ Bookmarks:${i}:Use\ Non-ASCII\ Font:" ~/Library/Preferences/com.googlecode.iterm2.plist)"
|
||||||
|
|
||||||
|
if [[ "$use_different_font" == "true" ]]; then
|
||||||
|
local non_ascii_font
|
||||||
|
non_ascii_font="$(/usr/libexec/PlistBuddy -c "Print :New\ Bookmarks:${i}:Non\ Ascii\ Font:" ~/Library/Preferences/com.googlecode.iterm2.plist)"
|
||||||
|
|
||||||
|
[[ "$term_font" != "$non_ascii_font" ]] && \
|
||||||
|
term_font="$term_font (normal) / $non_ascii_font (non-ascii)"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
;;
|
||||||
|
|
||||||
"deepin-terminal"*)
|
"deepin-terminal"*)
|
||||||
term_font="$(awk -F '=' '/font=/ {a=$2} /font_size/ {b=$2} END{print a " " b}' "${XDG_CONFIG_HOME}/deepin/deepin-terminal/config.conf")"
|
term_font="$(awk -F '=' '/font=/ {a=$2} /font_size/ {b=$2} END{print a " " b}' "${XDG_CONFIG_HOME}/deepin/deepin-terminal/config.conf")"
|
||||||
;;
|
;;
|
||||||
@@ -1663,6 +1734,34 @@ get_term_font() {
|
|||||||
[[ "$profile_filename" ]] && term_font="$(awk -F '=|,' '/Font=/ {print $2 " " $3}' "$profile_filename")"
|
[[ "$profile_filename" ]] && term_font="$(awk -F '=|,' '/Font=/ {print $2 " " $3}' "$profile_filename")"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
"mate-terminal")
|
||||||
|
# To get the actual config we have to create a temporarily file with the --save-config option.
|
||||||
|
mateterm_config="/tmp/mateterm.cfg"
|
||||||
|
|
||||||
|
# Ensure /tmp exists and we do not overwrite anything.
|
||||||
|
if [[ -d /tmp && ! -f "$mateterm_config" ]]; then
|
||||||
|
mate-terminal --save-config="$mateterm_config"
|
||||||
|
|
||||||
|
role="$(xprop -id "${WINDOWID}" WM_WINDOW_ROLE)"
|
||||||
|
role="${role##*= }"
|
||||||
|
|
||||||
|
term_id="$(grep -A1 "${role//\"}" "$mateterm_config")"
|
||||||
|
term_id="${term_id##*=}"
|
||||||
|
|
||||||
|
profile="$(grep -A1 "\[$term_id\]" "$mateterm_config")"
|
||||||
|
profile="${profile##*=}"
|
||||||
|
|
||||||
|
rm -f "$mateterm_config"
|
||||||
|
|
||||||
|
if [[ "$(gsettings get org.mate.terminal.profile:/org/mate/terminal/profiles/"${profile}"/ use-system-font)" == "true" ]]; then
|
||||||
|
term_font="$(gsettings get org.mate.interface monospace-font-name)"
|
||||||
|
else
|
||||||
|
term_font="$(gsettings get org.mate.terminal.profile:/org/mate/terminal/profiles/"${profile}"/ font)"
|
||||||
|
fi
|
||||||
|
term_font="$(trim_quotes "$term_font")"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
|
||||||
"mintty")
|
"mintty")
|
||||||
term_font="$(awk -F '=' '!/^($|#)/ && /Font/ {printf $2; exit}' "${HOME}/.minttyrc")"
|
term_font="$(awk -F '=' '!/^($|#)/ && /Font/ {printf $2; exit}' "${HOME}/.minttyrc")"
|
||||||
;;
|
;;
|
||||||
@@ -1685,7 +1784,7 @@ get_term_font() {
|
|||||||
|
|
||||||
"termite")
|
"termite")
|
||||||
[[ -f "${XDG_CONFIG_HOME}/termite/config" ]] && termite_config="${XDG_CONFIG_HOME}/termite/config"
|
[[ -f "${XDG_CONFIG_HOME}/termite/config" ]] && termite_config="${XDG_CONFIG_HOME}/termite/config"
|
||||||
term_font="$(awk -F '= ' '/\[options\]/ {opt=1} /^font/ {if(opt==1) a=$2; opt=0} END{print a}' "/etc/xdg/termite/config" "$termite_config")"
|
term_font="$(awk -F '= ' '/\[options\]/ {opt=1} /^\s*font/ {if(opt==1) a=$2; opt=0} END{print a}' "/etc/xdg/termite/config" "$termite_config")"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"urxvt" | "urxvtd" | "rxvt-unicode" | "xterm")
|
"urxvt" | "urxvtd" | "rxvt-unicode" | "xterm")
|
||||||
@@ -1744,6 +1843,10 @@ get_disk() {
|
|||||||
# Subtitle.
|
# Subtitle.
|
||||||
case "$disk_subtitle" in
|
case "$disk_subtitle" in
|
||||||
"name") disk_sub="${disk_info[0]}" ;;
|
"name") disk_sub="${disk_info[0]}" ;;
|
||||||
|
"dir")
|
||||||
|
disk_sub="${disk_info[5]/*\/}"
|
||||||
|
[[ -z "$disk_sub" ]] && disk_sub="${disk_info[5]}"
|
||||||
|
;;
|
||||||
*) disk_sub="${disk_info[5]}" ;;
|
*) disk_sub="${disk_info[5]}" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
@@ -1751,7 +1854,7 @@ get_disk() {
|
|||||||
case "$disk_display" in
|
case "$disk_display" in
|
||||||
"bar") disk="$(bar "$disk_perc" "100")" ;;
|
"bar") disk="$(bar "$disk_perc" "100")" ;;
|
||||||
"infobar") disk+=" $(bar "$disk_perc" "100")" ;;
|
"infobar") disk+=" $(bar "$disk_perc" "100")" ;;
|
||||||
"barinfo") disk="$(bar "$disk_perc" "100") $disk" ;;
|
"barinfo") disk="$(bar "$disk_perc" "100")${info_color} $disk" ;;
|
||||||
"perc") disk="${disk_perc}% $(bar "$disk_perc" "100")" ;;
|
"perc") disk="${disk_perc}% $(bar "$disk_perc" "100")" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
@@ -1767,26 +1870,24 @@ get_disk() {
|
|||||||
get_battery() {
|
get_battery() {
|
||||||
case "$os" in
|
case "$os" in
|
||||||
"Linux")
|
"Linux")
|
||||||
# We use 'prin' here and exit the function early so that we can
|
# We use 'prin' here so that we can do multi battery support
|
||||||
# do multi battery support with a single battery per line.
|
# with a single battery per line.
|
||||||
for bat in "/sys/class/power_supply/BAT"*; do
|
for bat in "/sys/class/power_supply/"{BAT,axp288_fuel_gauge}*; do
|
||||||
capacity="$(< "${bat}/capacity")"
|
capacity="$(< "${bat}/capacity")"
|
||||||
status="$(< "${bat}/status")"
|
status="$(< "${bat}/status")"
|
||||||
|
|
||||||
# Fix for bash on Windows 10 which includes /proc files
|
if [[ "$capacity" ]]; then
|
||||||
# for battery usage despite there not being a battery
|
|
||||||
# installed.
|
|
||||||
[[ -z "$capacity" ]] && return
|
|
||||||
|
|
||||||
battery="${capacity}% [${status}]"
|
battery="${capacity}% [${status}]"
|
||||||
|
|
||||||
case "$battery_display" in
|
case "$battery_display" in
|
||||||
"bar") battery="$(bar "$capacity" 100)" ;;
|
"bar") battery="$(bar "$capacity" 100)" ;;
|
||||||
"infobar") battery+=" $(bar "$capacity" 100)" ;;
|
"infobar") battery+=" $(bar "$capacity" 100)" ;;
|
||||||
"barinfo") battery="$(bar "$capacity" 100) ${battery}" ;;
|
"barinfo") battery="$(bar "$capacity" 100)${info_color} ${battery}" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
bat="${bat/*axp288_fuel_gauge}"
|
||||||
prin "${subtitle:+${subtitle}${bat: -1}}" "$battery"
|
prin "${subtitle:+${subtitle}${bat: -1}}" "$battery"
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
return
|
return
|
||||||
;;
|
;;
|
||||||
@@ -1840,14 +1941,15 @@ get_battery() {
|
|||||||
case "$battery_display" in
|
case "$battery_display" in
|
||||||
"bar") battery="$(bar "${battery/'%'*}" 100)" ;;
|
"bar") battery="$(bar "${battery/'%'*}" 100)" ;;
|
||||||
"infobar") battery="${battery} $(bar "${battery/'%'*}" 100)" ;;
|
"infobar") battery="${battery} $(bar "${battery/'%'*}" 100)" ;;
|
||||||
"barinfo") battery="$(bar "${battery/'%'*}" 100) ${battery}" ;;
|
"barinfo") battery="$(bar "${battery/'%'*}" 100)${info_color} ${battery}" ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
|
|
||||||
get_local_ip() {
|
get_local_ip() {
|
||||||
case "$os" in
|
case "$os" in
|
||||||
"Linux" | "BSD" | "Solaris" | "AIX")
|
"Linux" | "BSD" | "Solaris" | "AIX")
|
||||||
local_ip="$(ip route get 1 | awk '{print $NF;exit}')"
|
local_ip="$(ip route get 1 | awk -F'src' '{print $2; exit}')"
|
||||||
|
local_ip="${local_ip/uid*}"
|
||||||
[[ -z "$local_ip" ]] && local_ip="$(ifconfig -a | awk '/broadcast/ {print $2; exit}')"
|
[[ -z "$local_ip" ]] && local_ip="$(ifconfig -a | awk '/broadcast/ {print $2; exit}')"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
@@ -1900,7 +2002,7 @@ get_install_date() {
|
|||||||
"Windows")
|
"Windows")
|
||||||
case "$kernel_name" in
|
case "$kernel_name" in
|
||||||
"CYGWIN"*) install_file="/cygdrive/c/Windows/explorer.exe" ;;
|
"CYGWIN"*) install_file="/cygdrive/c/Windows/explorer.exe" ;;
|
||||||
"MSYS"*) install_file="/c/Windows/explorer.exe" ;;
|
"MSYS"* | "MINGW"*) install_file="/c/Windows/explorer.exe" ;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
"Haiku") install_file="/boot" ;;
|
"Haiku") install_file="/boot" ;;
|
||||||
@@ -1930,6 +2032,10 @@ get_install_date() {
|
|||||||
install_date="$(convert_time "${install_date[@]}")"
|
install_date="$(convert_time "${install_date[@]}")"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
get_locale() {
|
||||||
|
locale="$sys_locale"
|
||||||
|
}
|
||||||
|
|
||||||
get_cols() {
|
get_cols() {
|
||||||
if [[ "$color_blocks" == "on" ]]; then
|
if [[ "$color_blocks" == "on" ]]; then
|
||||||
# Convert the width to space chars.
|
# Convert the width to space chars.
|
||||||
@@ -1949,22 +2055,22 @@ get_cols() {
|
|||||||
done
|
done
|
||||||
|
|
||||||
# Convert height into spaces.
|
# Convert height into spaces.
|
||||||
printf -v spaces "%${block_height}s"
|
printf -v block_spaces "%${block_height}s"
|
||||||
|
|
||||||
# Convert the spaces into rows of blocks.
|
# Convert the spaces into rows of blocks.
|
||||||
[[ "$blocks" ]] && cols+="${spaces// /${blocks}${reset}nl}"
|
[[ "$blocks" ]] && cols+="${block_spaces// /${blocks}${reset}nl}"
|
||||||
[[ "$blocks2" ]] && cols+="${spaces// /${blocks2}${reset}nl}"
|
[[ "$blocks2" ]] && cols+="${block_spaces// /${blocks2}${reset}nl}"
|
||||||
|
|
||||||
# Add newlines to the string.
|
# Add newlines to the string.
|
||||||
cols="${cols%%'nl'}"
|
cols="${cols%%'nl'}"
|
||||||
cols="${cols//nl/\\n\\033[${text_padding}C${zws}}"
|
cols="${cols//nl/\\n\\033[${text_padding}C${zws}}"
|
||||||
|
|
||||||
|
# Add block height to info height.
|
||||||
|
info_height="$((info_height+=block_height+2))"
|
||||||
|
|
||||||
printf "%b\n" "\033[${text_padding}C${zws}${cols}"
|
printf "%b\n" "\033[${text_padding}C${zws}${cols}"
|
||||||
else
|
|
||||||
printf "\n"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
info_height="$((info_height+=block_height+2))"
|
|
||||||
unset -v blocks blocks2 cols
|
unset -v blocks blocks2 cols
|
||||||
|
|
||||||
# Tell info() that we printed manually.
|
# Tell info() that we printed manually.
|
||||||
@@ -1985,7 +2091,7 @@ image_backend() {
|
|||||||
"ascii") get_ascii ;;
|
"ascii") get_ascii ;;
|
||||||
"off") image_backend="off" ;;
|
"off") image_backend="off" ;;
|
||||||
|
|
||||||
"caca" | "catimg" | "jp2a" | "iterm2" | "tycat" | "w3m")
|
"caca" | "catimg" | "jp2a" | "iterm2" | "termpix" | "tycat" | "w3m" | "sixel")
|
||||||
get_image_source
|
get_image_source
|
||||||
|
|
||||||
if [[ ! -f "$image" ]]; then
|
if [[ ! -f "$image" ]]; then
|
||||||
@@ -1997,7 +2103,6 @@ image_backend() {
|
|||||||
|
|
||||||
if [[ "$term_width" ]] && ((term_width >= 1)); then
|
if [[ "$term_width" ]] && ((term_width >= 1)); then
|
||||||
clear
|
clear
|
||||||
zws=" "
|
|
||||||
else
|
else
|
||||||
to_ascii "Image: Failed to find terminal window size."
|
to_ascii "Image: Failed to find terminal window size."
|
||||||
err "Image: Check the 'Images in the terminal' wiki page for more info,"
|
err "Image: Check the 'Images in the terminal' wiki page for more info,"
|
||||||
@@ -2011,7 +2116,7 @@ image_backend() {
|
|||||||
|
|
||||||
*)
|
*)
|
||||||
err "Image: Unknown image backend specified '$image_backend'."
|
err "Image: Unknown image backend specified '$image_backend'."
|
||||||
err "Image: Valid backends are: 'ascii', 'caca', 'catimg', 'jp2a', 'iterm2', 'off', 'tycat', 'w3m')"
|
err "Image: Valid backends are: 'ascii', 'caca', 'catimg', 'jp2a', 'iterm2', 'off', 'sixel', 'termpix', 'tycat', 'w3m')"
|
||||||
err "Image: Falling back to ascii mode."
|
err "Image: Falling back to ascii mode."
|
||||||
get_ascii
|
get_ascii
|
||||||
;;
|
;;
|
||||||
@@ -2115,7 +2220,29 @@ get_image_source() {
|
|||||||
|
|
||||||
get_wallpaper() {
|
get_wallpaper() {
|
||||||
case "$os" in
|
case "$os" in
|
||||||
"Linux" | "BSD" | "Solaris" | "MINIX" | "AIX")
|
"Mac OS X")
|
||||||
|
image="$(osascript -e 'tell application "System Events" to picture of current desktop')"
|
||||||
|
;;
|
||||||
|
|
||||||
|
"Windows")
|
||||||
|
case "$distro" in
|
||||||
|
"Windows XP")
|
||||||
|
case "$kernel_name" in
|
||||||
|
"CYGWIN"*) image="/cygdrive/c/Documents and Settings/${USER}" ;;
|
||||||
|
"MSYS2"* | "MINGW*") image="/c/Documents and Settings/${USER}" ;;
|
||||||
|
esac
|
||||||
|
image+="/Local Settings/Application Data/Microsoft"
|
||||||
|
image+="/Wallpaper1.bmp"
|
||||||
|
;;
|
||||||
|
|
||||||
|
"Windows"*)
|
||||||
|
image="$APPDATA/Microsoft/Windows/Themes"
|
||||||
|
image+="/TranscodedWallpaper.jpg"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
|
||||||
|
*)
|
||||||
# Get DE if user has disabled the function.
|
# Get DE if user has disabled the function.
|
||||||
((de_run != 1)) && get_de
|
((de_run != 1)) && get_de
|
||||||
|
|
||||||
@@ -2146,28 +2273,6 @@ get_wallpaper() {
|
|||||||
image="${image/'file://'}"
|
image="${image/'file://'}"
|
||||||
image="$(trim_quotes "$image")"
|
image="$(trim_quotes "$image")"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"Mac OS X")
|
|
||||||
image="$(osascript -e 'tell application "System Events" to picture of current desktop')"
|
|
||||||
;;
|
|
||||||
|
|
||||||
"Windows")
|
|
||||||
case "$distro" in
|
|
||||||
"Windows XP")
|
|
||||||
case "$kernel_name" in
|
|
||||||
"CYGWIN"*) image="/cygdrive/c/Documents and Settings/${USER}" ;;
|
|
||||||
"MSYS2"*) image="/c/Documents and Settings/${USER}" ;;
|
|
||||||
esac
|
|
||||||
image+="/Local Settings/Application Data/Microsoft"
|
|
||||||
image+="/Wallpaper1.bmp"
|
|
||||||
;;
|
|
||||||
|
|
||||||
"Windows"*)
|
|
||||||
image="$APPDATA/Microsoft/Windows/Themes"
|
|
||||||
image+="/TranscodedWallpaper.jpg"
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
;;
|
|
||||||
esac
|
esac
|
||||||
|
|
||||||
# If image is an xml file, don't use it.
|
# If image is an xml file, don't use it.
|
||||||
@@ -2233,7 +2338,7 @@ get_term_size() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Get terminal width/height if \033[14t is unsupported.
|
# Get terminal width/height if \033[14t is unsupported.
|
||||||
if [[ -z "$term_width" && "$image_backend" == "w3m" ]]; then
|
if [[ -z "$term_width" ]]; then
|
||||||
if type -p xdotool >/dev/null 2>&1; then
|
if type -p xdotool >/dev/null 2>&1; then
|
||||||
current_window="$(xdotool getactivewindow)"
|
current_window="$(xdotool getactivewindow)"
|
||||||
source <(xdotool getwindowgeometry --shell "$current_window")
|
source <(xdotool getwindowgeometry --shell "$current_window")
|
||||||
@@ -2384,23 +2489,32 @@ make_thumbnail() {
|
|||||||
display_image() {
|
display_image() {
|
||||||
case "$image_backend" in
|
case "$image_backend" in
|
||||||
"caca")
|
"caca")
|
||||||
img2txt -W "$((width / font_width)))" -H "$((height / font_height))" --gamma=0.6 "$image" || to_off "Image: catimg failed to display the image."
|
img2txt -W "$((width / font_width)))" -H "$((height / font_height))" --gamma=0.6 "$image" || to_off "Image: libcaca failed to display the image."
|
||||||
zws=
|
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"catimg")
|
"catimg")
|
||||||
catimg -w "$((width * 2 / font_width))" -r 0 "$image" || to_off "Image: catimg failed to display the image."
|
catimg -w "$((width * 2 / font_width))" -r 0 "$image" || to_off "Image: catimg failed to display the image."
|
||||||
zws=
|
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"jp2a")
|
"jp2a")
|
||||||
jp2a --width="$((width / font_width))" --colors "$image" || to_off "Image: jp2a failed to display the image."
|
jp2a --width="$((width / font_width))" --colors "$image" || to_off "Image: jp2a failed to display the image."
|
||||||
zws=
|
;;
|
||||||
|
|
||||||
|
"sixel")
|
||||||
|
img2sixel -w "$width" "$image" || to_off "Image: libsixel failed to display the image."
|
||||||
|
;;
|
||||||
|
|
||||||
|
"termpix")
|
||||||
|
termpix --width "$((width / font_width))" "$image" || to_off "Image: termpix failed to display the image."
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"iterm2")
|
"iterm2")
|
||||||
printf "%b\a\n" "\033]1337;File=width=${width}px;height=${height}px;inline=1:$(base64 < "$image")"
|
iterm_cmd="\033]1337;File=width=${width}px;height=${height}px;inline=1:$(base64 < "$image")"
|
||||||
zws=
|
|
||||||
|
# Tmux requires an additional escape sequence for this to work.
|
||||||
|
[[ -n "$TMUX" ]] && iterm_cmd="\033Ptmux;\033${iterm_cmd}\033\\"
|
||||||
|
|
||||||
|
printf "%b\a\n" "$iterm_cmd"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"tycat")
|
"tycat")
|
||||||
@@ -2415,6 +2529,8 @@ display_image() {
|
|||||||
sleep 0.05
|
sleep 0.05
|
||||||
printf "%b\n" "0;1;$xoffset;$yoffset;$width;$height;;;;;$image\n4;\n3;" |\
|
printf "%b\n" "0;1;$xoffset;$yoffset;$width;$height;;;;;$image\n4;\n3;" |\
|
||||||
"${w3m_img_path:-false}" -bg "$background_color" >/dev/null & 2>&1 || to_off "Image: w3m-img failed to display the image."
|
"${w3m_img_path:-false}" -bg "$background_color" >/dev/null & 2>&1 || to_off "Image: w3m-img failed to display the image."
|
||||||
|
|
||||||
|
zws="\xE2\x80\x8B\x20"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
@@ -2438,17 +2554,14 @@ to_off() {
|
|||||||
err "$1"
|
err "$1"
|
||||||
image_backend="off"
|
image_backend="off"
|
||||||
text_padding=
|
text_padding=
|
||||||
zws=
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# SCREENSHOT
|
# SCREENSHOT
|
||||||
|
|
||||||
take_scrot() {
|
take_scrot() {
|
||||||
if [[ -d "$scrot_dir" ]]; then
|
|
||||||
scrot_program "${scrot_dir}${scrot_name}" 2>/dev/null
|
scrot_program "${scrot_dir}${scrot_name}" 2>/dev/null
|
||||||
else
|
|
||||||
printf "%s\n" "Screenshot: $scrot_dir doesn't exist. Edit the config file or create the directory to take screenshots."
|
err "Scrot: Saved screenshot as: ${scrot_dir}${scrot_name}"
|
||||||
fi
|
|
||||||
|
|
||||||
[[ "$scrot_upload" == "on" ]] && scrot_upload
|
[[ "$scrot_upload" == "on" ]] && scrot_upload
|
||||||
}
|
}
|
||||||
@@ -2489,13 +2602,16 @@ scrot_upload() {
|
|||||||
|
|
||||||
scrot_args() {
|
scrot_args() {
|
||||||
scrot="on"
|
scrot="on"
|
||||||
case "$2" in
|
|
||||||
"-"* | "") ;;
|
if [[ "$2" =~ \.(png|jpg|jpe|jpeg|gif)$ ]]; then
|
||||||
*)
|
|
||||||
scrot_name="${2##*/}"
|
scrot_name="${2##*/}"
|
||||||
scrot_dir="${2/$scrot_name}"
|
scrot_dir="${2/$scrot_name}"
|
||||||
;;
|
|
||||||
esac
|
elif [[ -d "$2" ]]; then
|
||||||
|
scrot_dir="$2"
|
||||||
|
else
|
||||||
|
scrot_dir="${PWD:+${PWD}/}"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
scrot_program() {
|
scrot_program() {
|
||||||
@@ -2621,10 +2737,11 @@ get_underline() {
|
|||||||
|
|
||||||
get_line_break() {
|
get_line_break() {
|
||||||
# Print it directly.
|
# Print it directly.
|
||||||
printf "%s\n" "${zws}"
|
printf "%b\n" "${zws}"
|
||||||
|
|
||||||
# Calculate info height.
|
# Calculate info height.
|
||||||
((++info_height))
|
((++info_height))
|
||||||
|
line_breaks+="\n"
|
||||||
|
|
||||||
# Tell info() that we printed manually.
|
# Tell info() that we printed manually.
|
||||||
prin=1
|
prin=1
|
||||||
@@ -2728,12 +2845,12 @@ get_distro_colors() {
|
|||||||
;;
|
;;
|
||||||
|
|
||||||
"arch_small")
|
"arch_small")
|
||||||
set_colors 4 7 1
|
set_colors 6 7 1
|
||||||
ascii_file="arch_small"
|
ascii_file="arch_small"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"arch_old")
|
"arch_old")
|
||||||
set_colors 4 7 1
|
set_colors 6 7 1
|
||||||
ascii_file="arch_old"
|
ascii_file="arch_old"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
@@ -2742,8 +2859,13 @@ get_distro_colors() {
|
|||||||
ascii_file="archbox"
|
ascii_file="archbox"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
"ARCHlabs"*)
|
||||||
|
set_colors 6 6 7 1
|
||||||
|
ascii_file="archlabs"
|
||||||
|
;;
|
||||||
|
|
||||||
"Arch"*)
|
"Arch"*)
|
||||||
set_colors 4 4 7 1
|
set_colors 6 6 7 1
|
||||||
ascii_file="arch"
|
ascii_file="arch"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
@@ -2817,6 +2939,11 @@ get_distro_colors() {
|
|||||||
ascii_file="deepin"
|
ascii_file="deepin"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
"DesaOS")
|
||||||
|
set_colors 2 7
|
||||||
|
ascii_file="desaos"
|
||||||
|
;;
|
||||||
|
|
||||||
"Devuan"*)
|
"Devuan"*)
|
||||||
set_colors 5 7
|
set_colors 5 7
|
||||||
ascii_file="devuan"
|
ascii_file="devuan"
|
||||||
@@ -2997,11 +3124,21 @@ get_distro_colors() {
|
|||||||
ascii_file="netrunner"
|
ascii_file="netrunner"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
"Nitrux"*)
|
||||||
|
set_colors 4
|
||||||
|
ascii_file="nitrux"
|
||||||
|
;;
|
||||||
|
|
||||||
"NixOS"*)
|
"NixOS"*)
|
||||||
set_colors 4 6
|
set_colors 4 6
|
||||||
ascii_file="nixos"
|
ascii_file="nixos"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
"OBRevenge"*)
|
||||||
|
set_colors 1 7 3
|
||||||
|
ascii_file="obrevenge"
|
||||||
|
;;
|
||||||
|
|
||||||
"openbsd_small")
|
"openbsd_small")
|
||||||
set_colors 3 7 6 1 8
|
set_colors 3 7 6 1 8
|
||||||
ascii_file="openbsd_small"
|
ascii_file="openbsd_small"
|
||||||
@@ -3132,6 +3269,11 @@ get_distro_colors() {
|
|||||||
ascii_file="slackware"
|
ascii_file="slackware"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
"SliTaz"*)
|
||||||
|
set_colors 3 3
|
||||||
|
ascii_file="slitaz"
|
||||||
|
;;
|
||||||
|
|
||||||
"SmartOS"*)
|
"SmartOS"*)
|
||||||
set_colors 6 7
|
set_colors 6 7
|
||||||
ascii_file="smartos"
|
ascii_file="smartos"
|
||||||
@@ -3187,11 +3329,21 @@ get_distro_colors() {
|
|||||||
ascii_file="ubuntu-gnome"
|
ascii_file="ubuntu-gnome"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
"Ubuntu-MATE"*)
|
||||||
|
set_colors 2 7
|
||||||
|
ascii_file="ubuntu-mate"
|
||||||
|
;;
|
||||||
|
|
||||||
"ubuntu_old")
|
"ubuntu_old")
|
||||||
set_colors 1 7 3
|
set_colors 1 7 3
|
||||||
ascii_file="ubuntu_old"
|
ascii_file="ubuntu_old"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
"Ubuntu-Studio")
|
||||||
|
set_colors 6 7
|
||||||
|
ascii_file="ubuntu-studio"
|
||||||
|
;;
|
||||||
|
|
||||||
"Ubuntu"*)
|
"Ubuntu"*)
|
||||||
set_colors 1 7 3
|
set_colors 1 7 3
|
||||||
ascii_file="ubuntu"
|
ascii_file="ubuntu"
|
||||||
@@ -3309,8 +3461,8 @@ set_text_colors() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
case "$bar_color_total $1" in
|
case "$bar_color_total $1" in
|
||||||
"distro "[736]) bar_color_total="$c2" ;;
|
"distro "[736]) bar_color_total="$(color "$1")" ;;
|
||||||
"distro "[0-9]) bar_color_total="$c1" ;;
|
"distro "[0-9]) bar_color_total="$(color "$2")" ;;
|
||||||
*) bar_color_total="$(color "$bar_color_total")" ;;
|
*) bar_color_total="$(color "$bar_color_total")" ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
@@ -3318,7 +3470,7 @@ set_text_colors() {
|
|||||||
color() {
|
color() {
|
||||||
case "$1" in
|
case "$1" in
|
||||||
[0-6]) printf "%b" "${reset}\033[3${1}m" ;;
|
[0-6]) printf "%b" "${reset}\033[3${1}m" ;;
|
||||||
7 | "fg") printf "%b" "$reset" ;;
|
7 | "fg") printf "%b" "\033[37m${reset}" ;;
|
||||||
*) printf "%b" "\033[38;5;${1}m" ;;
|
*) printf "%b" "\033[38;5;${1}m" ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
@@ -3426,14 +3578,14 @@ bar() {
|
|||||||
printf -v total "%$((bar_length - elapsed))s"
|
printf -v total "%$((bar_length - elapsed))s"
|
||||||
|
|
||||||
# Set the colors and swap the spaces for $bar_char_.
|
# Set the colors and swap the spaces for $bar_char_.
|
||||||
bar+="${bar_color_elapsed}${prog// /$bar_char_elapsed}"
|
bar+="${bar_color_elapsed}${prog// /${bar_char_elapsed}}"
|
||||||
bar+="${bar_color_total}${total// /$bar_char_total}"
|
bar+="${bar_color_total}${total// /${bar_char_total}}"
|
||||||
|
|
||||||
# Borders.
|
# Borders.
|
||||||
[[ "$bar_border" == "on" ]] && \
|
[[ "$bar_border" == "on" ]] && \
|
||||||
bar="$(color fg)[${bar}$(color fg)]"
|
bar="$(color fg)[${bar}$(color fg)]"
|
||||||
|
|
||||||
printf "%b\n" "${bar}${info_color}"
|
printf "%b" "${bar}${info_color}"
|
||||||
}
|
}
|
||||||
|
|
||||||
cache() {
|
cache() {
|
||||||
@@ -3497,34 +3649,30 @@ get_term_padding() {
|
|||||||
|
|
||||||
dynamic_prompt() {
|
dynamic_prompt() {
|
||||||
case "$image_backend" in
|
case "$image_backend" in
|
||||||
"ascii") ;;
|
"ascii") printf "\n" ;;
|
||||||
"off") return ;;
|
"off") return ;;
|
||||||
*)
|
*)
|
||||||
get_term_padding 2>/dev/null
|
get_term_padding
|
||||||
|
lines="$(((border + height + yoffset) / font_height))"
|
||||||
# Calculate image height in terminal cells.
|
image_prompt="on"
|
||||||
lines="$(((border * 2 + height + yoffset) / font_height))"
|
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
# If the info is higher than the ascii/image place the prompt
|
# If the info is higher than the ascii/image place the prompt
|
||||||
# based on the info height instead of the ascii/image height.
|
# based on the info height instead of the ascii/image height.
|
||||||
if ((lines < info_height)); then
|
if ((lines < info_height)); then
|
||||||
printf "\n"
|
[[ "$image_prompt" ]] && printf "\n"
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
|
[[ "$image_prompt" ]] && printf "%b\n" "$line_breaks"
|
||||||
lines="$((lines - info_height))"
|
lines="$((lines - info_height))"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Set the prompt location.
|
# Print a newline if color blocks are disabled.
|
||||||
if ((lines < 0)); then
|
[[ -z "$block_spaces" ]] && printf "\n"
|
||||||
printf "%b" "\033[${lines/-}A"
|
|
||||||
else
|
|
||||||
printf "%b" "\033[${lines}B"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Add some padding.
|
# Set the prompt location.
|
||||||
printf "\n\n\n\n"
|
((lines > 0)) && printf "%b" "\033[${lines}B"
|
||||||
}
|
}
|
||||||
|
|
||||||
old_functions() {
|
old_functions() {
|
||||||
@@ -3574,6 +3722,9 @@ old_options() {
|
|||||||
|
|
||||||
# Birthday was renamed to Install Date in 3.0
|
# Birthday was renamed to Install Date in 3.0
|
||||||
[[ -n "$birthday_time" ]] && { err "Config: \$birthday_time is deprecated, use \3install_time instead."; install_time="$birthday_time"; }
|
[[ -n "$birthday_time" ]] && { err "Config: \$birthday_time is deprecated, use \3install_time instead."; install_time="$birthday_time"; }
|
||||||
|
|
||||||
|
# Scrot dir was removed in 3.1.0.
|
||||||
|
[[ -n "$scrot_dir" ]] && scrot_dir=
|
||||||
}
|
}
|
||||||
|
|
||||||
cache_uname() {
|
cache_uname() {
|
||||||
@@ -3724,6 +3875,7 @@ INFO:
|
|||||||
|
|
||||||
NOTE: This only supports Linux with cpufreq.
|
NOTE: This only supports Linux with cpufreq.
|
||||||
|
|
||||||
|
--speed_shorthand on/off Whether or not to show decimals in CPU speed.
|
||||||
--cpu_shorthand type Shorten the output of CPU
|
--cpu_shorthand type Shorten the output of CPU
|
||||||
Possible values: name, speed, tiny, on, off
|
Possible values: name, speed, tiny, on, off
|
||||||
--cpu_cores type Whether or not to display the number of CPU cores
|
--cpu_cores type Whether or not to display the number of CPU cores
|
||||||
@@ -3764,12 +3916,15 @@ INFO:
|
|||||||
|
|
||||||
NOTE: Multiple values can be given. (--disk_show '/' '/dev/sdc1')
|
NOTE: Multiple values can be given. (--disk_show '/' '/dev/sdc1')
|
||||||
|
|
||||||
--disk_subtitle name/mount What information to append to the Disk subtitle.
|
--disk_subtitle type What information to append to the Disk subtitle.
|
||||||
|
Takes: name, mount, dir
|
||||||
|
|
||||||
'name' shows the disk's name (sda1, sda2, etc)
|
'name' shows the disk's name (sda1, sda2, etc)
|
||||||
|
|
||||||
'mount' shows the disk's mount point (/, /mnt/Local Disk, etc)
|
'mount' shows the disk's mount point (/, /mnt/Local Disk, etc)
|
||||||
|
|
||||||
|
'dir' shows the basename of the disks's path. (/, Local Disk, etc)
|
||||||
|
|
||||||
--ip_host url URL to query for public IP
|
--ip_host url URL to query for public IP
|
||||||
--song_shorthand on/off Print the Artist/Title on separate lines
|
--song_shorthand on/off Print the Artist/Title on separate lines
|
||||||
--install_time on/off Enable/Disable showing the time in Install Date output.
|
--install_time on/off Enable/Disable showing the time in Install Date output.
|
||||||
@@ -3807,7 +3962,7 @@ BARS:
|
|||||||
|
|
||||||
IMAGE BACKEND:
|
IMAGE BACKEND:
|
||||||
--backend backend Which image backend to use.
|
--backend backend Which image backend to use.
|
||||||
Possible values: 'ascii', 'caca', 'catimg', 'jp2a', 'iterm2', 'off', 'tycat', 'w3m'
|
Possible values: 'ascii', 'caca', 'catimg', 'jp2a', 'iterm2', 'off', 'sixel', 'tycat', 'w3m'
|
||||||
--source source Which image or ascii file to use.
|
--source source Which image or ascii file to use.
|
||||||
Possible values: 'auto', 'ascii', 'wallpaper', '/path/to/img', '/path/to/ascii', '/path/to/dir/'
|
Possible values: 'auto', 'ascii', 'wallpaper', '/path/to/img', '/path/to/ascii', '/path/to/dir/'
|
||||||
--ascii source Shortcut to use 'ascii' backend.
|
--ascii source Shortcut to use 'ascii' backend.
|
||||||
@@ -3815,6 +3970,8 @@ IMAGE BACKEND:
|
|||||||
--catimg source Shortcut to use 'catimg' backend.
|
--catimg source Shortcut to use 'catimg' backend.
|
||||||
--iterm2 source Shortcut to use 'iterm2' backend.
|
--iterm2 source Shortcut to use 'iterm2' backend.
|
||||||
--jp2a source Shortcut to use 'jp2a' backend.
|
--jp2a source Shortcut to use 'jp2a' backend.
|
||||||
|
--sixel source Shortcut to use 'sixel' backend.
|
||||||
|
--termpix source Shortcut to use 'termpix' backend.
|
||||||
--tycat source Shortcut to use 'tycat' backend.
|
--tycat source Shortcut to use 'tycat' backend.
|
||||||
--w3m source Shortcut to use 'w3m' backend.
|
--w3m source Shortcut to use 'w3m' backend.
|
||||||
--off Shortcut to use 'off' backend.
|
--off Shortcut to use 'off' backend.
|
||||||
@@ -3843,6 +4000,7 @@ ASCII:
|
|||||||
Possible values: bar, infobar, barinfo, off
|
Possible values: bar, infobar, barinfo, off
|
||||||
|
|
||||||
IMAGE:
|
IMAGE:
|
||||||
|
--loop Redraw the image constantly until Ctrl+C is used. This fixes issues in some terminals emulators when using image mode.
|
||||||
--size 00px | --size 00% How to size the image.
|
--size 00px | --size 00% How to size the image.
|
||||||
Possible values: auto, 00px, 00%, none
|
Possible values: auto, 00px, 00%, none
|
||||||
--crop_mode mode Which crop mode to use
|
--crop_mode mode Which crop mode to use
|
||||||
@@ -3927,6 +4085,7 @@ get_args() {
|
|||||||
"--cpu_cores") cpu_cores="$2" ;;
|
"--cpu_cores") cpu_cores="$2" ;;
|
||||||
"--cpu_speed") cpu_speed="$2" ;;
|
"--cpu_speed") cpu_speed="$2" ;;
|
||||||
"--speed_type") speed_type="$2" ;;
|
"--speed_type") speed_type="$2" ;;
|
||||||
|
"--speed_shorthand") speed_shorthand="$2" ;;
|
||||||
"--distro_shorthand") distro_shorthand="$2" ;;
|
"--distro_shorthand") distro_shorthand="$2" ;;
|
||||||
"--kernel_shorthand") kernel_shorthand="$2" ;;
|
"--kernel_shorthand") kernel_shorthand="$2" ;;
|
||||||
"--uptime_shorthand") uptime_shorthand="$2" ;;
|
"--uptime_shorthand") uptime_shorthand="$2" ;;
|
||||||
@@ -4017,7 +4176,7 @@ get_args() {
|
|||||||
# Image backend
|
# Image backend
|
||||||
"--backend") image_backend="$2" ;;
|
"--backend") image_backend="$2" ;;
|
||||||
"--source") image_source="$2" ;;
|
"--source") image_source="$2" ;;
|
||||||
"--ascii" | "--caca" | "--catimg" | "--jp2a" | "--iterm2" | "--off" | "--tycat" | "--w3m")
|
"--ascii" | "--caca" | "--catimg" | "--jp2a" | "--iterm2" | "--off" | "--sixel" | "--termpix" | "--tycat" | "--w3m")
|
||||||
image_backend="${1/--}"
|
image_backend="${1/--}"
|
||||||
case "$2" in
|
case "$2" in
|
||||||
"-"* | "") ;;
|
"-"* | "") ;;
|
||||||
@@ -4026,6 +4185,7 @@ get_args() {
|
|||||||
;;
|
;;
|
||||||
|
|
||||||
# Image options
|
# Image options
|
||||||
|
"--loop") image_loop="on" ;;
|
||||||
"--image_size" | "--size") image_size="$2" ;;
|
"--image_size" | "--size") image_size="$2" ;;
|
||||||
"--crop_mode") crop_mode="$2" ;;
|
"--crop_mode") crop_mode="$2" ;;
|
||||||
"--crop_offset") crop_offset="$2" ;;
|
"--crop_offset") crop_offset="$2" ;;
|
||||||
@@ -4114,7 +4274,6 @@ main() {
|
|||||||
printf "\033[?25l\033[?7l"
|
printf "\033[?25l\033[?7l"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# get_image_backend
|
|
||||||
image_backend
|
image_backend
|
||||||
old_functions
|
old_functions
|
||||||
get_cache_dir
|
get_cache_dir
|
||||||
@@ -4131,6 +4290,9 @@ main() {
|
|||||||
# Show error messages.
|
# Show error messages.
|
||||||
[[ "$verbose" == "on" ]] && printf "%b" "$err" >&2
|
[[ "$verbose" == "on" ]] && printf "%b" "$err" >&2
|
||||||
|
|
||||||
|
# If `--loop` was used, constantly redraw the image.
|
||||||
|
while [[ "$image_loop" == "on" && "$image_backend" == "w3m" ]]; do display_image; sleep 1s; done
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
21
neofetch.1
21
neofetch.1
@@ -1,5 +1,5 @@
|
|||||||
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.3.
|
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.3.
|
||||||
.TH NEOFETCH "1" "January 2017" "Neofetch 3.0.1" "User Commands"
|
.TH NEOFETCH "1" "April 2017" "Neofetch 3.1.0-git" "User Commands"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
Neofetch \- A fast, highly customizable system info script
|
Neofetch \- A fast, highly customizable system info script
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
@@ -30,6 +30,9 @@ scaling_current, scaling_min, scaling_max
|
|||||||
.IP
|
.IP
|
||||||
NOTE: This only supports Linux with cpufreq.
|
NOTE: This only supports Linux with cpufreq.
|
||||||
.TP
|
.TP
|
||||||
|
\fB\-\-speed_shorthand\fR on/off
|
||||||
|
Whether or not to show decimals in CPU speed.
|
||||||
|
.TP
|
||||||
\fB\-\-cpu_shorthand\fR type
|
\fB\-\-cpu_shorthand\fR type
|
||||||
Shorten the output of CPU
|
Shorten the output of CPU
|
||||||
Possible values: name, speed, tiny, on, off
|
Possible values: name, speed, tiny, on, off
|
||||||
@@ -96,12 +99,15 @@ Possible values: '/', '/dev/sdXX', '/path/to/mount point'
|
|||||||
.IP
|
.IP
|
||||||
NOTE: Multiple values can be given. (\fB\-\-disk_show\fR '/' '/dev/sdc1')
|
NOTE: Multiple values can be given. (\fB\-\-disk_show\fR '/' '/dev/sdc1')
|
||||||
.TP
|
.TP
|
||||||
\fB\-\-disk_subtitle\fR name/mount
|
\fB\-\-disk_subtitle\fR type
|
||||||
What information to append to the Disk subtitle.
|
What information to append to the Disk subtitle.
|
||||||
|
Takes: name, mount, dir
|
||||||
.IP
|
.IP
|
||||||
\&'name' shows the disk's name (sda1, sda2, etc)
|
\&'name' shows the disk's name (sda1, sda2, etc)
|
||||||
.IP
|
.IP
|
||||||
\&'mount' shows the disk's mount point (/, \fI\,/mnt/Local\/\fP Disk, etc)
|
\&'mount' shows the disk's mount point (/, \fI\,/mnt/Local\/\fP Disk, etc)
|
||||||
|
.IP
|
||||||
|
\&'dir' shows the basename of the disks's path. (/, Local Disk, etc)
|
||||||
.TP
|
.TP
|
||||||
\fB\-\-ip_host\fR url
|
\fB\-\-ip_host\fR url
|
||||||
URL to query for public IP
|
URL to query for public IP
|
||||||
@@ -175,7 +181,7 @@ Possible values: bar, infobar, barinfo, off
|
|||||||
.TP
|
.TP
|
||||||
\fB\-\-backend\fR backend
|
\fB\-\-backend\fR backend
|
||||||
Which image backend to use.
|
Which image backend to use.
|
||||||
Possible values: 'ascii', 'caca', 'catimg', 'jp2a', 'iterm2', 'off', 'tycat', 'w3m'
|
Possible values: 'ascii', 'caca', 'catimg', 'jp2a', 'iterm2', 'off', 'sixel', 'tycat', 'w3m'
|
||||||
.TP
|
.TP
|
||||||
\fB\-\-source\fR source
|
\fB\-\-source\fR source
|
||||||
Which image or ascii file to use.
|
Which image or ascii file to use.
|
||||||
@@ -196,6 +202,12 @@ Shortcut to use 'iterm2' backend.
|
|||||||
\fB\-\-jp2a\fR source
|
\fB\-\-jp2a\fR source
|
||||||
Shortcut to use 'jp2a' backend.
|
Shortcut to use 'jp2a' backend.
|
||||||
.TP
|
.TP
|
||||||
|
\fB\-\-sixel\fR source
|
||||||
|
Shortcut to use 'sixel' backend.
|
||||||
|
.TP
|
||||||
|
\fB\-\-termpix\fR source
|
||||||
|
Shortcut to use 'termpix' backend.
|
||||||
|
.TP
|
||||||
\fB\-\-tycat\fR source
|
\fB\-\-tycat\fR source
|
||||||
Shortcut to use 'tycat' backend.
|
Shortcut to use 'tycat' backend.
|
||||||
.TP
|
.TP
|
||||||
@@ -235,6 +247,9 @@ Hide the info text and only show the ascii logo.
|
|||||||
Possible values: bar, infobar, barinfo, off
|
Possible values: bar, infobar, barinfo, off
|
||||||
.SS "IMAGE:"
|
.SS "IMAGE:"
|
||||||
.TP
|
.TP
|
||||||
|
\fB\-\-loop\fR
|
||||||
|
Redraw the image constantly until Ctrl+C is used. This fixes issues in some terminals emulators when using image mode.
|
||||||
|
.TP
|
||||||
\fB\-\-size\fR 00px | \fB\-\-size\fR 00%
|
\fB\-\-size\fR 00px | \fB\-\-size\fR 00%
|
||||||
How to size the image.
|
How to size the image.
|
||||||
Possible values: auto, 00px, 00%, none
|
Possible values: auto, 00px, 00%, none
|
||||||
|
|||||||
Reference in New Issue
Block a user