diff --git a/1.8.md b/1.8.md index f07cbbfd..177f2482 100644 --- a/1.8.md +++ b/1.8.md @@ -44,6 +44,7 @@ bottom of the window. See [#279](https://github.com/dylanaraps/neofetch/pull/279 - Added support for Devuan Linux. - Added support for GalliumOS. - Added support for PacBSD. **[@vendion](https://github.com/vendion)** +- Added support for Rosa. - Added support for Solaris (Oracle / OpenIndiana). **[@konimex](https://github.com/konimex)** - Added support for macOS Sierra. **[@iandrewt](https://github.com/iandrewt)** - Fixed various iOS related issues. diff --git a/ascii/distro/rosa b/ascii/distro/rosa new file mode 100644 index 00000000..6e8115bc --- /dev/null +++ b/ascii/distro/rosa @@ -0,0 +1,22 @@ +"\ +${c1} ROSAROSAROSAROSAR + ROSA AROS + ROS SAROSAROSAROSAR AROS + RO ROSAROSAROSAROSAROSAR RO + ARO AROSAROSAROSARO AROS ROS + ARO ROSAROS OSAR ROSA ROS + RO AROSA ROSAROSAROSA ROSAR RO +RO ROSAR ROSAROSAROSAR R ROSARO RO +RO ROSA AROSAROSAROSA AR ROSARO AR +RO AROS ROSAROSAROSA ROS AROSARO AR +RO AROS ROSAROSARO ROSARO ROSARO AR +RO ROS AROSAROS ROSAROSA AROSAR AR +RO ROSA ROS ROSAROSAR ROSARO RO + RO ROS AROSAROSAROSA ROSARO AR + ARO ROSA ROSAROSAROS AROSAR ARO + ARO OROSA R ROSAROS ROS + RO AROSAROS AROSAROSAR RO + AROS AROSAROSAROSARO AROS + ROSA SARO + ROSAROSAROSAROSAR +" diff --git a/neofetch b/neofetch index 71f3cfd0..ae22c880 100755 --- a/neofetch +++ b/neofetch @@ -118,6 +118,9 @@ getdistro() { [ "$osx_buildversion" == "off" ] && \ distro="${distro/ ${osx_build}}" + + [ "${ascii_distro:-auto}" == "auto" ] && \ + ascii_distro="$(trim "$distro")" } # }}} @@ -1948,8 +1951,9 @@ getimage() { fi # Get terminal lines and columns - lines="$(tput lines)" - columns="$(tput cols)" + term_blocks="$(stty size)" + columns="${term_blocks/* }" + lines="${term_blocks/ *}" # Calculate font size font_width="$((term_width / columns))" @@ -2303,7 +2307,7 @@ colors() { ascii_distro="redhat" ;; - "Kogaion"* | "Elementary"* | "GalliumOS"* | "OpenWrt"*) + "Kogaion"* | "Elementary"* | "GalliumOS"* | "Rosa"* | "OpenWrt"*) setcolors 4 7 ;; @@ -3006,9 +3010,14 @@ getargs() { # Call Functions and Finish Up {{{ main() { + getos getdefaultconfig 2>/dev/null getargs "$@" - getos + getdistro + + # Get colors and bold + bold + colors # Restore cursor and clear screen on ctrl+c trap 'printf "\033[?25h"; clear; exit' 2 @@ -3016,15 +3025,6 @@ main() { # If the script exits for any reason, unhide the cursor. trap 'printf "\033[?25h"' EXIT - # Distro detection - getdistro - [ "${ascii_distro:-auto}" == "auto" ] && \ - ascii_distro="$(trim "$distro")" - - # Get colors and bold - bold - colors - # Clear the scren clear @@ -3048,7 +3048,7 @@ main() { fi # Move cursor to the top - [ "$image" != "off" ] && printf "\033[0H" + printf "\033[0H" # Print the info printinfo