From 31dbdaa85a7ad161e0f0fd070785f2804ee4f45b Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Tue, 17 May 2016 17:20:19 +1000 Subject: [PATCH] Add support for OS X terminals --- neofetch | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/neofetch b/neofetch index 238b2cb4..48f35a7c 100755 --- a/neofetch +++ b/neofetch @@ -1738,7 +1738,13 @@ getfont () { # Terminal Emulator {{{ getterm () { - [ -n "$ITERM_PROFILE" ] && term="iTerm2" + # Workaround for OS X systems that + # don't support the block below. + case "$TERM_PROGRAM" in + "iTerm.app") term="iTerm2" ;; + "Terminal.app") term="Apple Terminal" ;; + *) term="${TERM_PROGRAM/\.app}" ;; + esac # Check $PPID for terminal emulator. if [ -z "$term" ]; then