sorin-ionescu / prezto

The configuration framework for Zsh

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

git-hub-browse stopped working

idcrook opened this issue · comments

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

$ gRb
# opens repo url by passing to $BROWSER

Actual behavior

$ gRb
git-hub-browse: browser not set or set to a non-existent browser

Steps to Reproduce

See above.

Versions

In a3643f1 "git: Optimize scripts for git helper functions"

...

-  if (( $+commands[$BROWSER] )); then
+  if [[ -z "$BROWSER" ]]; then
     "$BROWSER" "$url"
  • Prezto commit:
  • ZSH version:
  • OS information: