From 71f0575b2b73afaa6e59a16a3fcdf356d5e3e1cc Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Sun, 28 Aug 2016 08:59:11 +1000
Subject: [PATCH 01/21] Add ascii art and distro detection

---
 ascii/distro/android | 15 +++++++++++++++
 neofetch             |  3 +++
 2 files changed, 18 insertions(+)
 create mode 100644 ascii/distro/android

diff --git a/ascii/distro/android b/ascii/distro/android
new file mode 100644
index 00000000..ff6d4949
--- /dev/null
+++ b/ascii/distro/android
@@ -0,0 +1,15 @@
+"\
+${c1}     ╲ ▁▂▂▂▁ ╱
+     ▄███████▄
+    ▄██${c2} ${c1}███${c2} ${c1}██▄
+   ▄███████████▄
+▄█ ▄▄▄▄▄▄▄▄▄▄▄▄▄ █▄
+██ █████████████ ██
+██ █████████████ ██
+██ █████████████ ██
+██ █████████████ ██
+   █████████████
+    ███████████
+     ██     ██
+     ██     ██
+"
diff --git a/neofetch b/neofetch
index 5220093e..f6943144 100755
--- a/neofetch
+++ b/neofetch
@@ -124,6 +124,9 @@ getdistro() {
             elif type -p crux >/dev/null 2>&1; then
                 distro="$(crux)"
 
+            elif [ -d "/system/app/" ] && [ -d "/system/priv-app" ]; then
+                distro="Android $(getprop ro.build.version.release)"
+
             else
                 distro="$(awk -F 'NAME=' '/^NAME=/ {printf $2}' /etc/*ease)"
                 distro="${distro//\"}"

From 12ba2f925af9494ebe877cfb22793a7d95f39014 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Sun, 28 Aug 2016 09:03:40 +1000
Subject: [PATCH 02/21] Add previous PR

---
 neofetch | 13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/neofetch b/neofetch
index f6943144..6b5162a4 100755
--- a/neofetch
+++ b/neofetch
@@ -237,6 +237,10 @@ getuptime() {
                     uptime="$(uptime | awk -F ':[0-9]{2}+[a-z][a-z]  |(, ){1}+' '{printf $2}')"
                 ;;
 
+                "Android"*)
+                    uptime=$(uptime | awk -F ': |, ' '{printf $2}')
+                ;;
+
                 *)
                     uptime="$(uptime -p)"
                     [ "$uptime" == "up " ] && uptime="up $(awk -F'.' '{print $1}' /proc/uptime) seconds"
@@ -407,6 +411,8 @@ getpackages() {
             packages="$(pkg list | wc -l)"
         ;;
     esac
+
+    [ "$packages" == 0 ] && unset packages
 }
 
 # }}}
@@ -1554,6 +1560,7 @@ getdisk() {
 
             case "$distro" in
                 "OpenWRT"*) df_flags="-h"; df_dir="rootfs" ;;
+                "Android"*) return ;;
             esac
         ;;
 
@@ -1619,8 +1626,8 @@ getbattery() {
                     *) index="$battery_num" ;;
                 esac
 
-                batteries=($(cat "/sys/class/power_supply/BAT$battery_num/capacity"))
-                battery_state=($(cat "/sys/class/power_supply/BAT${battery_num}/status"))
+                batteries=($(cat /sys/class/power_supply/battery/capacity /sys/class/power_supply/BAT${battery_num}/capacity))
+                battery_state=($(cat /sys/class/power_supply/battery/status /sys/class/power_supply/BAT${battery_num}/status))
 
                 # Get the subtitle and reassign it so it doesn't change.
                 title="$subtitle"
@@ -2411,7 +2418,7 @@ colors() {
             ascii_distro="mint"
         ;;
 
-        "LMDE"* | "Chapeau"*)
+        "LMDE"* | "Chapeau"* | "Android"*)
             setcolors 2 7
         ;;
 

From 5444ecdf6db3f13616ca65aceff1e4ea58d115a0 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Sun, 28 Aug 2016 10:49:35 +1000
Subject: [PATCH 03/21] Fix padding on Android

---
 neofetch | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/neofetch b/neofetch
index 6b5162a4..0cc63954 100755
--- a/neofetch
+++ b/neofetch
@@ -1968,14 +1968,13 @@ getascii() {
     ascii_strip="${ascii_strip//'\\'/ }"
     ascii_strip="${ascii_strip//'\'}"
 
-    # Get lines/columns of the ascii file in pure bash.
+    # Get length of the ascii file.
     ascii_length=0
-    lines=1
-    while IFS='\n' read -r line 2>/dev/null; do
-        [ ${#line} -gt "$ascii_length" ] && ascii_length=${#line}
-        lines=$((lines+=1))
+    while IFS='' read -r line 2>/dev/null; do
+        [ "${#line}" -gt "$ascii_length" ] && ascii_length="${#line}"
     done <<< "$ascii_strip"
 
+    lines="$(printf "%s\n" "$ascii_strip" | wc -l)"
     padding="\033[$((ascii_length + gap))C"
     printf "%b%s" "$print"
     export LC_ALL=C

From 76cc33f95f5c7856268bc5e939f499f4b32b6ba6 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Sun, 28 Aug 2016 11:41:27 +1000
Subject: [PATCH 04/21] Fix padding on android

---
 neofetch | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/neofetch b/neofetch
index 0cc63954..4cef6725 100755
--- a/neofetch
+++ b/neofetch
@@ -1974,6 +1974,11 @@ getascii() {
         [ "${#line}" -gt "$ascii_length" ] && ascii_length="${#line}"
     done <<< "$ascii_strip"
 
+    # Workaround for calculating length of block chars
+    # when locale is set to 'C'
+    block_char="█"
+    [ "${#block_char}" == 3 ] && ascii_length="$((ascii_length / 3 + 2))"
+
     lines="$(printf "%s\n" "$ascii_strip" | wc -l)"
     padding="\033[$((ascii_length + gap))C"
     printf "%b%s" "$print"

From bd7ebdfe4bb0142d6227edea7cfd9f3a0822252f Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Sun, 28 Aug 2016 11:47:56 +1000
Subject: [PATCH 05/21] Fix CPU name on android

---
 neofetch | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/neofetch b/neofetch
index 4cef6725..6488eed1 100755
--- a/neofetch
+++ b/neofetch
@@ -637,7 +637,7 @@ getcpu() {
     case "$os" in
         "Linux" | "Windows")
             # Get cpu name
-            cpu="$(awk -F ': | @' '/model name/ {printf $2; exit}' /proc/cpuinfo)"
+            cpu="$(awk -F ': | @' '/model name|Processor/ {printf $2; exit}' /proc/cpuinfo)"
 
             # Get cpu speed
             if [ -d "/sys/devices/system/cpu/cpu0/cpufreq" ]; then

From 0a2fa2b55886adb7f1ed830e8554f6342c53fbc8 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Sun, 28 Aug 2016 12:03:23 +1000
Subject: [PATCH 06/21] Better uptime command that will work accross uptime
 versions

---
 neofetch | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/neofetch b/neofetch
index 6488eed1..848393be 100755
--- a/neofetch
+++ b/neofetch
@@ -238,7 +238,10 @@ getuptime() {
                 ;;
 
                 "Android"*)
-                    uptime=$(uptime | awk -F ': |, ' '{printf $2}')
+                    uptime=$(uptime | awk -F ' up' '{print $2}')
+                    time="${time//[0-9] user*}"
+                    time="${time//load average:*}"
+                    time="${time%,*} ${time##*,}"
                 ;;
 
                 *)

From 26de54e55512614d313dca4817ed8d8924751e19 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Mon, 29 Aug 2016 14:22:10 +1000
Subject: [PATCH 07/21] Fix new issues

---
 config/config | 2 +-
 neofetch      | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/config/config b/config/config
index 84665f5b..40cc7eb7 100644
--- a/config/config
+++ b/config/config
@@ -85,7 +85,7 @@ uptime_shorthand="off"
 
 # Show the path to $SHELL
 # --shell_path on/off
-shell_path="on"
+shell_path="off"
 
 # Show $SHELL's version
 # --shell_version on/off
diff --git a/neofetch b/neofetch
index 848393be..d8f08b6d 100755
--- a/neofetch
+++ b/neofetch
@@ -240,7 +240,7 @@ getuptime() {
                 "Android"*)
                     uptime=$(uptime | awk -F ' up' '{print $2}')
                     time="${time//[0-9] user*}"
-                    time="${time//load average:*}"
+                    time="${time//load average*}"
                     time="${time%,*} ${time##*,}"
                 ;;
 

From 7889c093b29eaebe849ceb6e0e370c7f11152c94 Mon Sep 17 00:00:00 2001
From: Muhammad Herdiansyah <herdiansyah@openmailbox.org>
Date: Mon, 29 Aug 2016 21:20:46 +0700
Subject: [PATCH 08/21] Added and changed some Android commands

Included:
- Added model support for Android
- Changed CPU command to use native Android ones
---
 neofetch | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/neofetch b/neofetch
index d8f08b6d..499ad62a 100755
--- a/neofetch
+++ b/neofetch
@@ -41,7 +41,10 @@ getos() {
 getmodel() {
     case "$os" in
         "Linux")
-            if [ -f /sys/devices/virtual/dmi/id/product_name ] ||\
+            if [ -d "/system/app/" ] && [ -d "/system/priv-app" ]; then
+                model="$(getprop ro.product.brand) $(getprop ro.product.model)"
+
+            elif [ -f /sys/devices/virtual/dmi/id/product_name ] ||\
                [ -f /sys/devices/virtual/dmi/id/product_version ]; then
                 model="$(cat /sys/devices/virtual/dmi/id/product_{name,version} 2>/dev/null)"
                 model="${model/To Be Filled*}"
@@ -640,7 +643,12 @@ getcpu() {
     case "$os" in
         "Linux" | "Windows")
             # Get cpu name
-            cpu="$(awk -F ': | @' '/model name|Processor/ {printf $2; exit}' /proc/cpuinfo)"
+            case "$distro" in
+                "Android"*)
+                    cpu="$(getprop ro.product.board)" ;;
+                *)
+                    cpu="$(awk -F ': | @' '/model name|Processor/ {printf $2; exit}' /proc/cpuinfo)" ;;
+            esac
 
             # Get cpu speed
             if [ -d "/sys/devices/system/cpu/cpu0/cpufreq" ]; then

From b3dcfe820c1ae1fdd9cebb6c3f57153022081678 Mon Sep 17 00:00:00 2001
From: Muhammad Herdiansyah <herdiansyah@openmailbox.org>
Date: Tue, 30 Aug 2016 07:26:13 +0700
Subject: [PATCH 09/21] Changed case

---
 neofetch | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/neofetch b/neofetch
index 499ad62a..b25c1e78 100755
--- a/neofetch
+++ b/neofetch
@@ -644,10 +644,8 @@ getcpu() {
         "Linux" | "Windows")
             # Get cpu name
             case "$distro" in
-                "Android"*)
-                    cpu="$(getprop ro.product.board)" ;;
-                *)
-                    cpu="$(awk -F ': | @' '/model name|Processor/ {printf $2; exit}' /proc/cpuinfo)" ;;
+                "Android"*) cpu="$(getprop ro.product.board)" ;;
+                *) cpu="$(awk -F ': | @' '/model name|Processor/ {printf $2; exit}' /proc/cpuinfo)" ;;
             esac
 
             # Get cpu speed

From 444c860e6180bb0d40039a26535671ee05b6b85b Mon Sep 17 00:00:00 2001
From: Muhammad Herdiansyah <herdiansyah@openmailbox.org>
Date: Tue, 30 Aug 2016 23:13:59 +0700
Subject: [PATCH 10/21] Fixed Android uptime

---
 neofetch | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/neofetch b/neofetch
index b25c1e78..97e5415c 100755
--- a/neofetch
+++ b/neofetch
@@ -242,9 +242,9 @@ getuptime() {
 
                 "Android"*)
                     uptime=$(uptime | awk -F ' up' '{print $2}')
-                    time="${time//[0-9] user*}"
-                    time="${time//load average*}"
-                    time="${time%,*} ${time##*,}"
+                    uptime="${uptime//[0-9] user*}"
+                    uptime="${uptime//load average*}"
+                    uptime="${uptime%,*} ${uptime##*,}"
                 ;;
 
                 *)

From 7a661b396649eefb92781640557595f6e0e57e39 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Thu, 20 Oct 2016 17:32:29 +1100
Subject: [PATCH 11/21] Fix bugs

---
 neofetch | 22 +++++++++++++++-------
 1 file changed, 15 insertions(+), 7 deletions(-)

diff --git a/neofetch b/neofetch
index bdbc12cf..cd3e9a8a 100755
--- a/neofetch
+++ b/neofetch
@@ -465,8 +465,6 @@ getpackages() {
             packages="$(pkg list | wc -l)"
         ;;
     esac
-
-    [ "$packages" == 0 ] && unset packages
 }
 
 # }}}
@@ -1736,8 +1734,17 @@ getbattery() {
                     *) index="$battery_num" ;;
                 esac
 
-                batteries=($(cat /sys/class/power_supply/battery/capacity /sys/class/power_supply/BAT${battery_num}/capacity))
-                battery_state=($(cat /sys/class/power_supply/battery/status /sys/class/power_supply/BAT${battery_num}/status))
+                case "$distro" in
+                    "Android"*)
+                        batteries="$(< /sys/class/power_supply/battery/capacity)"
+                        battery_state="$(< /sys/class/power_supply/battery/status)"
+                    ;;
+
+                    *)
+                        batteries=($(< /sys/class/power_supply/BAT${battery_num}/capacity))
+                        battery_state=($(< /sys/class/power_supply/BAT${battery_num}/status))
+                    ;;
+                esac
 
                 # Get the subtitle and reassign it so it doesn't change.
                 title="$subtitle"
@@ -2082,10 +2089,12 @@ getascii() {
     ascii_strip="${ascii_strip//'\\'/ }"
     ascii_strip="${ascii_strip//'\'}"
 
-    # Get length of the ascii file.
+    # Get lines/columns of the ascii file.
     ascii_length=0
-    while IFS='' read -r line 2>/dev/null; do
+    lines=1
+    while IFS='\n' read -r line 2>/dev/null; do
         [ "${#line}" -gt "$ascii_length" ] && ascii_length="${#line}"
+        lines="$((lines+=1))"
     done <<< "$ascii_strip"
 
     # Workaround for calculating length of block chars
@@ -2093,7 +2102,6 @@ getascii() {
     block_char="█"
     [ "${#block_char}" == 3 ] && ascii_length="$((ascii_length / 3 + 2))"
 
-    lines="$(printf "%s\n" "$ascii_strip" | wc -l)"
     padding="\033[$((ascii_length + gap))C"
     printf "%b%s" "$print"
     export LC_ALL=C

From 7862e3af5a14bfe0c3cf08130e18252cb1c02343 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Fri, 21 Oct 2016 09:15:03 +1100
Subject: [PATCH 12/21] Fix bugs

---
 neofetch | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/neofetch b/neofetch
index cd3e9a8a..8fc0ef72 100755
--- a/neofetch
+++ b/neofetch
@@ -465,6 +465,8 @@ getpackages() {
             packages="$(pkg list | wc -l)"
         ;;
     esac
+
+    [ "$packages" == "0" ] && unset packages
 }
 
 # }}}
@@ -1597,7 +1599,7 @@ getterm() {
     case "${name// }" in
         "${SHELL/*\/}" | *"sh" | "tmux"* | "screen") getterm "$parent" ;;
         "login" | "init") term="$(tty)" ;;
-        "ruby" | "1" | "systemd" | "sshd"* | "python"*) unset term ;;
+        "ruby" | "1" | "systemd" | "sshd"* | "python"* | "USER PID"*) unset term ;;
         "gnome-terminal-") term="gnome-terminal" ;;
         *) term="${name##*/}" ;;
     esac

From e5359dc31421d0bbe928229477744b4861d6e524 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Fri, 21 Oct 2016 14:45:36 +1100
Subject: [PATCH 13/21] Fix terminal output on android

---
 neofetch | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/neofetch b/neofetch
index 8fc0ef72..77305e67 100755
--- a/neofetch
+++ b/neofetch
@@ -1599,7 +1599,7 @@ getterm() {
     case "${name// }" in
         "${SHELL/*\/}" | *"sh" | "tmux"* | "screen") getterm "$parent" ;;
         "login" | "init") term="$(tty)" ;;
-        "ruby" | "1" | "systemd" | "sshd"* | "python"* | "USER PID"*) unset term ;;
+        "ruby" | "1" | "systemd" | "sshd"* | "python"* | "USER"*"PID"*) unset term ;;
         "gnome-terminal-") term="gnome-terminal" ;;
         *) term="${name##*/}" ;;
     esac

From 7bdf5f11685ab7442f7474965018afac0d6986b2 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Fri, 21 Oct 2016 17:19:03 +1100
Subject: [PATCH 14/21] Fix bug with block chars

---
 neofetch | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/neofetch b/neofetch
index 77305e67..e6151acc 100755
--- a/neofetch
+++ b/neofetch
@@ -2091,6 +2091,11 @@ getascii() {
     ascii_strip="${ascii_strip//'\\'/ }"
     ascii_strip="${ascii_strip//'\'}"
 
+    # Workaround for calculating length of block chars
+    # when locale is set to 'C'
+    block_char="█"
+    [ "${#block_char}" == 3 ] && ascii_strip="${ascii_strip//${block_char}/ }"
+
     # Get lines/columns of the ascii file.
     ascii_length=0
     lines=1
@@ -2099,11 +2104,6 @@ getascii() {
         lines="$((lines+=1))"
     done <<< "$ascii_strip"
 
-    # Workaround for calculating length of block chars
-    # when locale is set to 'C'
-    block_char="█"
-    [ "${#block_char}" == 3 ] && ascii_length="$((ascii_length / 3 + 2))"
-
     padding="\033[$((ascii_length + gap))C"
     printf "%b%s" "$print"
     export LC_ALL=C

From b13da1d9990a9e54326b25cc8828a82a97493197 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Fri, 21 Oct 2016 18:02:04 +1100
Subject: [PATCH 15/21] Fix C locale padding issues

---
 neofetch | 18 ++++++++++--------
 1 file changed, 10 insertions(+), 8 deletions(-)

diff --git a/neofetch b/neofetch
index e6151acc..1a0df36d 100755
--- a/neofetch
+++ b/neofetch
@@ -2091,19 +2091,16 @@ getascii() {
     ascii_strip="${ascii_strip//'\\'/ }"
     ascii_strip="${ascii_strip//'\'}"
 
-    # Workaround for calculating length of block chars
-    # when locale is set to 'C'
-    block_char="█"
-    [ "${#block_char}" == 3 ] && ascii_strip="${ascii_strip//${block_char}/ }"
-
     # Get lines/columns of the ascii file.
-    ascii_length=0
     lines=1
     while IFS='\n' read -r line 2>/dev/null; do
-        [ "${#line}" -gt "$ascii_length" ] && ascii_length="${#line}"
+        [ "${#line}" -gt "${ascii_length:-0}" ] && ascii_length="${#line}"
         lines="$((lines+=1))"
     done <<< "$ascii_strip"
 
+    # Overwrite padding if ascii_length_force is set.
+    [ "$ascii_length_force" ] && ascii_length="$ascii_length_force"
+
     padding="\033[$((ascii_length + gap))C"
     printf "%b%s" "$print"
     export LC_ALL=C
@@ -2595,10 +2592,15 @@ colors() {
             ascii_distro="mint"
         ;;
 
-        "LMDE"* | "Chapeau"* | "Bitrig"* | "Android"*)
+        "LMDE"* | "Chapeau"* | "Bitrig"*)
             setcolors 2 7
         ;;
 
+        "Android"*)
+            setcolors 2 7
+            ascii_length_force="19"
+        ;;
+
         "NetBSD"* | "Parabola"* | "Tails"* | "BLAG"*)
             setcolors 5 7
         ;;

From 6e47608bc5fc0292158eeab28e02510755005c74 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Fri, 21 Oct 2016 18:09:25 +1100
Subject: [PATCH 16/21] Don't do any dynamic prompt stuff in image off mode

---
 neofetch | 17 +++++++++--------
 1 file changed, 9 insertions(+), 8 deletions(-)

diff --git a/neofetch b/neofetch
index 1a0df36d..bbaa5986 100755
--- a/neofetch
+++ b/neofetch
@@ -2923,7 +2923,7 @@ kdeconfigdir() {
 dynamicprompt() {
     # Calculate image height in terminal cells.
     # The '+ 4' adds a gap between the prompt and the content.
-    [ "$image" != "ascii" ] && [ "$image" != "off" ] && \
+    [ "$image" != "ascii" ] && \
         lines="$((${height:-1} / ${font_height:-1} + 4))"
 
     # If the info is higher than the ascii/image place the prompt
@@ -3319,17 +3319,18 @@ main() {
 
         # Display the image if enabled
         displayimage
+
+        # Set cursor position next to ascii art
+        printf "\033[$((${lines:-4} - ${prompt_loc:-4}))A"
+
+        # Reset horizontal cursor position
+        printf "\033[9999999D"
     fi
 
-    # Set cursor position next to ascii art
-    printf "\033[$((${lines:-4} - ${prompt_loc:-4}))A"
-
-    # Reset horizontal cursor position
-    printf "\033[9999999D"
-
     # Print the info
     printinfo
-    dynamicprompt
+
+    [ "$image" != "off" ] && dynamicprompt
 
     # Re-enable line wrap
     printf "%b%s" "\033[?7h"

From edb6920df952325e57703eae43cc564d6debde17 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Fri, 21 Oct 2016 18:54:37 +1100
Subject: [PATCH 17/21] New android logo

---
 ascii/distro/android | 33 ++++++++++++++++++++-------------
 neofetch             | 10 +---------
 2 files changed, 21 insertions(+), 22 deletions(-)

diff --git a/ascii/distro/android b/ascii/distro/android
index ff6d4949..c77503dc 100644
--- a/ascii/distro/android
+++ b/ascii/distro/android
@@ -1,15 +1,22 @@
 "\
-${c1}     ╲ ▁▂▂▂▁ ╱
-     ▄███████▄
-    ▄██${c2} ${c1}███${c2} ${c1}██▄
-   ▄███████████▄
-▄█ ▄▄▄▄▄▄▄▄▄▄▄▄▄ █▄
-██ █████████████ ██
-██ █████████████ ██
-██ █████████████ ██
-██ █████████████ ██
-   █████████████
-    ███████████
-     ██     ██
-     ██     ██
+${c1}          /\`          \`/
+          \`o::/++++/::o\`
+        \`/syyyyyyyyyyyys/\`
+       -yyy/\`+yyyyyy+\`/yyy:
+      .yyyyysyyyyyyyysyyyyy-
+      :oooooooooooooooooooo/
+ :/:\` -////////////////////: \`:/:\`
++yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
++yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
++yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
++yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
++yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
++yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
+\`://\` +yyyyyyyyyyyyyyyyyyyyo \`://\`
+      +yyyyyyyyyyyyyyyyyyyyo
+      .oyyyyyyyyyyyyyyyyyyo.
+          /yyys    syyy+
+          /yyys    syyy+
+          /yyys    syyy+
+          .oso:    :oso.
 "
diff --git a/neofetch b/neofetch
index dcd23799..d070d377 100755
--- a/neofetch
+++ b/neofetch
@@ -2098,9 +2098,6 @@ getascii() {
         lines="$((lines+=1))"
     done <<< "$ascii_strip"
 
-    # Overwrite padding if ascii_length_force is set.
-    [ "$ascii_length_force" ] && ascii_length="$ascii_length_force"
-
     padding="\033[$((ascii_length + gap))C"
     printf "%b%s" "$print"
     export LC_ALL=C
@@ -2593,15 +2590,10 @@ colors() {
             ascii_distro="mint"
         ;;
 
-        "LMDE"* | "Chapeau"* | "Bitrig"*)
+        "LMDE"* | "Chapeau"* | "Bitrig"* | "Android"*)
             setcolors 2 7
         ;;
 
-        "Android"*)
-            setcolors 2 7
-            ascii_length_force="19"
-        ;;
-
         "NetBSD"* | "Parabola"* | "Tails"* | "BLAG"*)
             setcolors 5 7
         ;;

From 5df16a361d9268e81dd8fa387bd7aa621088f8fe Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Fri, 21 Oct 2016 19:01:01 +1100
Subject: [PATCH 18/21] revert new logo

---
 ascii/distro/android | 33 +++++++++++++--------------------
 1 file changed, 13 insertions(+), 20 deletions(-)

diff --git a/ascii/distro/android b/ascii/distro/android
index c77503dc..ff6d4949 100644
--- a/ascii/distro/android
+++ b/ascii/distro/android
@@ -1,22 +1,15 @@
 "\
-${c1}          /\`          \`/
-          \`o::/++++/::o\`
-        \`/syyyyyyyyyyyys/\`
-       -yyy/\`+yyyyyy+\`/yyy:
-      .yyyyysyyyyyyyysyyyyy-
-      :oooooooooooooooooooo/
- :/:\` -////////////////////: \`:/:\`
-+yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
-+yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
-+yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
-+yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
-+yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
-+yyyo +yyyyyyyyyyyyyyyyyyyyo +yyyo
-\`://\` +yyyyyyyyyyyyyyyyyyyyo \`://\`
-      +yyyyyyyyyyyyyyyyyyyyo
-      .oyyyyyyyyyyyyyyyyyyo.
-          /yyys    syyy+
-          /yyys    syyy+
-          /yyys    syyy+
-          .oso:    :oso.
+${c1}     ╲ ▁▂▂▂▁ ╱
+     ▄███████▄
+    ▄██${c2} ${c1}███${c2} ${c1}██▄
+   ▄███████████▄
+▄█ ▄▄▄▄▄▄▄▄▄▄▄▄▄ █▄
+██ █████████████ ██
+██ █████████████ ██
+██ █████████████ ██
+██ █████████████ ██
+   █████████████
+    ███████████
+     ██     ██
+     ██     ██
 "

From 7b62b8091c3b6958dc83618fb53c3bcd60e2965b Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Fri, 21 Oct 2016 19:01:25 +1100
Subject: [PATCH 19/21] revert old logo

---
 neofetch | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/neofetch b/neofetch
index d070d377..dcd23799 100755
--- a/neofetch
+++ b/neofetch
@@ -2098,6 +2098,9 @@ getascii() {
         lines="$((lines+=1))"
     done <<< "$ascii_strip"
 
+    # Overwrite padding if ascii_length_force is set.
+    [ "$ascii_length_force" ] && ascii_length="$ascii_length_force"
+
     padding="\033[$((ascii_length + gap))C"
     printf "%b%s" "$print"
     export LC_ALL=C
@@ -2590,10 +2593,15 @@ colors() {
             ascii_distro="mint"
         ;;
 
-        "LMDE"* | "Chapeau"* | "Bitrig"* | "Android"*)
+        "LMDE"* | "Chapeau"* | "Bitrig"*)
             setcolors 2 7
         ;;
 
+        "Android"*)
+            setcolors 2 7
+            ascii_length_force="19"
+        ;;
+
         "NetBSD"* | "Parabola"* | "Tails"* | "BLAG"*)
             setcolors 5 7
         ;;

From 0b5d25d9b52aa8240cb6295be88da7ed61a30e04 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Sat, 22 Oct 2016 09:49:59 +1100
Subject: [PATCH 20/21] Fix cursor bugs if ascii art is taller than info

---
 neofetch | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/neofetch b/neofetch
index 967a13eb..190f3c31 100755
--- a/neofetch
+++ b/neofetch
@@ -2940,6 +2940,8 @@ dynamicprompt() {
     if [ "$image" != "ascii" ]; then
         lines="$((${height:-1} / ${font_height:-1} + 2))"
         cursor_yoffset="$((${yoffset:-1} / ${font_height:-1}))"
+    else
+        cursor_yoffset="0 - 4"
     fi
 
     # If the info is higher than the ascii/image place the prompt
@@ -2954,7 +2956,7 @@ dynamicprompt() {
     [ "$image" != "off" ] && printf "\033[${lines/-*/0}B"
 
     # Add some padding
-    [ "$image_backend" != "w3m" ] && \
+    [ "$image" == "ascii" ] && \
     [ "$lines" -gt 0 ] && \
         printf "\n\n"
 }

From ad3a90219a25d0737049ab73522ce40ddb354273 Mon Sep 17 00:00:00 2001
From: Dylan Araps <dylan.araps@gmail.com>
Date: Sat, 22 Oct 2016 10:18:38 +1100
Subject: [PATCH 21/21] Fix cursor artifcats in termux

---
 neofetch | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/neofetch b/neofetch
index 2bd9be03..01052b32 100755
--- a/neofetch
+++ b/neofetch
@@ -2957,7 +2957,7 @@ dynamicprompt() {
 
     # Set the prompt location
     if [ "$lines" -lt 0 ]; then
-        printf "\033[${lines}A"
+        printf "\033[${lines/-}A"
     else
         printf "\033[${lines}B"
     fi