diff options
Diffstat (limited to 'functions')
-rw-r--r-- | functions/icons.zsh | 24 | ||||
-rw-r--r-- | functions/utilities.zsh | 14 |
2 files changed, 31 insertions, 7 deletions
diff --git a/functions/icons.zsh b/functions/icons.zsh index ed3482de..238b6b9e 100644 --- a/functions/icons.zsh +++ b/functions/icons.zsh @@ -39,10 +39,13 @@ case $POWERLEVEL9K_MODE in FAIL_ICON $'\u2718' # ✘ SYMFONY_ICON 'SF' NODE_ICON $'\u2B22' # ⬢ - MULTILINE_FIRST_PROMPT_PREFIX $'\u256D'$'\U2500' - MULTILINE_SECOND_PROMPT_PREFIX $'\u2570'$'\U2500 ' + MULTILINE_FIRST_PROMPT_PREFIX $'\u256D'$'\U2500' # ╭─ + MULTILINE_NEWLINE_PROMPT_PREFIX $'\u251C'$'\U2500' # ├─ + MULTILINE_LAST_PROMPT_PREFIX $'\u2570'$'\U2500 ' # ╰─ APPLE_ICON $'\uE26E' # + WINDOWS_ICON $'\uE26F' # FREEBSD_ICON $'\U1F608 ' # 😈 + ANDROID_ICON $'\uE270' # LINUX_ICON $'\uE271' # SUNOS_ICON $'\U1F31E ' # 🌞 HOME_ICON $'\uE12C' # @@ -109,9 +112,12 @@ case $POWERLEVEL9K_MODE in SYMFONY_ICON 'SF' NODE_ICON $'\u2B22' # ⬢ MULTILINE_FIRST_PROMPT_PREFIX $'\u256D'$'\U2500' # ╭─ - MULTILINE_SECOND_PROMPT_PREFIX $'\u2570'$'\U2500 ' # ╰─ + MULTILINE_NEWLINE_PROMPT_PREFIX $'\u251C'$'\U2500' # ├─ + MULTILINE_LAST_PROMPT_PREFIX $'\u2570'$'\U2500 ' # ╰─ APPLE_ICON $'\uF179' # + WINDOWS_ICON $'\uF17A' # FREEBSD_ICON $'\U1F608 ' # 😈 + ANDROID_ICON $'\uE17B' # LINUX_ICON $'\uF17C' # SUNOS_ICON $'\uF185 ' # HOME_ICON $'\uF015' # @@ -174,9 +180,12 @@ case $POWERLEVEL9K_MODE in SYMFONY_ICON $'\uE757' # NODE_ICON $'\uE617 ' # MULTILINE_FIRST_PROMPT_PREFIX $'\u256D'$'\U2500' # ╭─ - MULTILINE_SECOND_PROMPT_PREFIX $'\u2570'$'\U2500 ' # ╰─ + MULTILINE_NEWLINE_PROMPT_PREFIX $'\u251C'$'\U2500' # ├─ + MULTILINE_LAST_PROMPT_PREFIX $'\u2570'$'\U2500 ' # ╰─ APPLE_ICON $'\uF179' # + WINDOWS_ICON $'\uF17A' # FREEBSD_ICON $'\UF30E ' # + ANDROID_ICON $'\uF17B' # LINUX_ICON $'\uF17C' # SUNOS_ICON $'\uF185 ' # HOME_ICON $'\uF015' # @@ -238,10 +247,13 @@ case $POWERLEVEL9K_MODE in FAIL_ICON $'\u2718' # ✘ SYMFONY_ICON 'SF' NODE_ICON $'\u2B22' # ⬢ - MULTILINE_FIRST_PROMPT_PREFIX $'\u256D'$'\u2500' - MULTILINE_SECOND_PROMPT_PREFIX $'\u2570'$'\u2500 ' + MULTILINE_FIRST_PROMPT_PREFIX $'\u256D'$'\U2500' # ╭─ + MULTILINE_NEWLINE_PROMPT_PREFIX $'\u251C'$'\U2500' # ├─ + MULTILINE_LAST_PROMPT_PREFIX $'\u2570'$'\U2500 ' # ╰─ APPLE_ICON 'OSX' + WINDOWS_ICON 'WIN' FREEBSD_ICON 'BSD' + ANDROID_ICON 'And' LINUX_ICON 'Lx' SUNOS_ICON 'Sun' HOME_ICON '' diff --git a/functions/utilities.zsh b/functions/utilities.zsh index 22b53c6a..9bd82060 100644 --- a/functions/utilities.zsh +++ b/functions/utilities.zsh @@ -79,12 +79,16 @@ function getRelevantItem() { done } -# OS detection for the `os_icon` segment +# OS detection case $(uname) in Darwin) OS='OSX' OS_ICON=$(print_icon 'APPLE_ICON') ;; + CYGWIN_NT-*) + OS='Windows' + OS_ICON=$(print_icon 'WINDOWS_ICON') + ;; FreeBSD) OS='BSD' OS_ICON=$(print_icon 'FREEBSD_ICON') @@ -100,6 +104,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' |