Closed idcrook closed 2 years ago
Function git-hub-browse intends to check for BROWSER envariable to be set, but instead errors with a message if BROWSER envariable is set.
git-hub-browse
Found source of issue: code tests -z $BROWSER
-z $BROWSER
should instead be ! -z $BROWSER or -n $BROWSER
! -z $BROWSER
-n $BROWSER
$ gRb # opens repo url by passing to $BROWSER
$ gRb git-hub-browse: browser not set or set to a non-existent browser
See above.
In https://github.com/sorin-ionescu/prezto/commit/a3643f124e91d9ef55da5c0bcf2b3be257e84843 "git: Optimize scripts for git helper functions"
... - if (( $+commands[$BROWSER] )); then + if [[ -z "$BROWSER" ]]; then "$BROWSER" "$url"
Description
Function
git-hub-browse
intends to check for BROWSER envariable to be set, but instead errors with a message if BROWSER envariable is set.Found source of issue: code tests
-z $BROWSER
should instead be
! -z $BROWSER
or-n $BROWSER
Expected behavior
Actual behavior
Steps to Reproduce
See above.
Versions
In https://github.com/sorin-ionescu/prezto/commit/a3643f124e91d9ef55da5c0bcf2b3be257e84843 "git: Optimize scripts for git helper functions"