Take the tour ×  I'm running a script (in tmuxinator) that tries
to source another script (rvm). rvm explicitly does not allow
sourcing from sh. I didn't think that would be a problem,
because the shebang in the tmuxinator script is   but when I
insert the code suggested by the rvm people to source rvm from a
script,    source "$HOME/.rvm/scripts/rvm"  -I get  sh: 6: [[:
not found  Why is sh being used as the interpreter there? I've
also used #!/usr/bin/zsh (which is the value of $SHELL in the
interactive shell from which I called the script) and
#!/usr/bin/env zsh, but they give the same complaint.
share|improve this question On the face of what you're saying,
it should work, so you must have left something out. Post or
link to the full script that you've added this snippet to, and
tell us exactly how it's invoked. –  Gilles Apr 12 at 21:56 I've
actually pared the script down to just what I posted and get the
same result. The script is being called by Ruby, with the
Kernel#exec method, but I can't find any