Skip to content

Commit

Permalink
#30: warn if bash is not installed
Browse files Browse the repository at this point in the history
  • Loading branch information
chisui committed Mar 31, 2022
1 parent f8574f2 commit 4eb69b0
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions nix-shell.plugin.zsh
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@

NIX_SHELL_PLUGIN_DIR=${0:a:h}

which bash > /dev/null 2>&1
if [ "$?" -ne "0" ]; then
echo
echo " WARNING: bash is not installed."
echo " for zsh-nix-shell to work bash has to be in PATH"
echo
fi


# extracts packages argument from args and passes them in $NIX_SHELL_PACKAGES variable.
function nix-shell() {
local -a ARGS; ARGS=("$@")
Expand Down

0 comments on commit 4eb69b0

Please sign in to comment.