diff options
author | guixxx <guixxx@users.noreply.github.com> | 2017-04-13 00:39:10 +0300 |
---|---|---|
committer | Ben Hilburn <bhilburn@gmail.com> | 2017-04-19 01:02:37 +0300 |
commit | 421f506bf8041a6a1e80b3bb77f03fcb9657fdd0 (patch) | |
tree | 18a1a6ad3d6356720e921696b1417fdab9acba0f /functions | |
parent | ea2d02d08fd952d7fdbee827052f78d4287e75d8 (diff) |
Improve logic
Diffstat (limited to 'functions')
-rw-r--r-- | functions/utilities.zsh | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/functions/utilities.zsh b/functions/utilities.zsh index bdfce5fd..8f676caf 100644 --- a/functions/utilities.zsh +++ b/functions/utilities.zsh @@ -100,6 +100,14 @@ case $(uname) in Linux) OS='Linux' OS_ICON=$(print_icon 'LINUX_ICON') + + # Check if we're running on Android + case $(uname -o 2>/dev/null) in + Android) + OS='Android' + OS_ICON=$(print_icon 'ANDROID_ICON') + ;; + esac ;; SunOS) OS='Solaris' @@ -111,15 +119,6 @@ case $(uname) in ;; esac -# Not all OSes support the '-o' parameter -# That's why this second condition is needed -case $(uname -o 2>/dev/null) in - Android) - OS='Android' - OS_ICON=$(print_icon 'ANDROID_ICON') - ;; -esac - # Determine the correct sed parameter. # # `sed` is unfortunately not consistent across OSes when it comes to flags. |