Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

fix for issue #136 #137

Merged
merged 1 commit into from

2 participants

@erichs
Owner

issue #136 was found to be caused by an aliased 'ls' command that
generated rogue values for 'plugin' in the enable/disable-plugin()
functions. this commit fixes that by forcing the shell to disregard
aliased 'ls' commands.

@erichs erichs fix for issue #136
issue #136 was found to be caused by an aliased 'ls' command that
generated rogue values for 'plugin' in the enable/disable-plugin()
functions. this commit fixes that by forcing the shell to disregard
aliased 'ls' commands.
bffae2a
@tswicegood tswicegood merged commit 311f95b into Bash-it:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on May 20, 2012
  1. @erichs

    fix for issue #136

    erichs authored
    issue #136 was found to be caused by an aliased 'ls' command that
    generated rogue values for 'plugin' in the enable/disable-plugin()
    functions. this commit fixes that by forcing the shell to disregard
    aliased 'ls' commands.
This page is out of date. Refresh to see the latest.
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/helpers.bash
View
4 lib/helpers.bash
@@ -74,7 +74,7 @@ disable-plugin ()
fi
done
else
- typeset plugin=$(ls $BASH_IT/plugins/enabled/$1.*bash 2>/dev/null | head -1)
+ typeset plugin=$(command ls $BASH_IT/plugins/enabled/$1.*bash 2>/dev/null | head -1)
if [ ! -h $plugin ]; then
printf '%s\n' 'sorry, that does not appear to be an enabled plugin.'
return
@@ -107,7 +107,7 @@ enable-plugin ()
fi
done
else
- typeset plugin=$(ls $BASH_IT/plugins/available/$1.*bash 2>/dev/null | head -1)
+ typeset plugin=$(command ls $BASH_IT/plugins/available/$1.*bash 2>/dev/null | head -1)
if [ -z "$plugin" ]; then
printf '%s\n' 'sorry, that does not appear to be an available plugin.'
return
Something went wrong with that request. Please try again.