Skip to content

Commit

Permalink
Merge branch 'js/iterm-is-on-osx'
Browse files Browse the repository at this point in the history
Add more logic to detect graphic environment of OS X by simply
checking TERM_PROGRAM has some value, not Apple_Terminal, to detect
iTerm.app and any other.

* js/iterm-is-on-osx:
  git-web--browse: recognize any TERM_PROGRAM as a GUI terminal on OS X
  • Loading branch information
Junio C Hamano committed Apr 3, 2013
2 parents b9c78e9 + be537e4 commit ed23f31
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions git-web--browse.sh
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,8 @@ if test -z "$browser" ; then
browser_candidates="w3m elinks links lynx"
fi
# SECURITYSESSIONID indicates an OS X GUI login session
if test -n "$SECURITYSESSIONID" \
-o "$TERM_PROGRAM" = "Apple_Terminal" ; then
if test -n "$SECURITYSESSIONID" || test -n "$TERM_PROGRAM"
then
browser_candidates="open $browser_candidates"
fi
# /bin/start indicates MinGW
Expand Down

0 comments on commit ed23f31

Please sign in to comment.