zsh-users
 help / color / mirror / code / Atom feed
* zsh will not run scripts as /bin/bash even with #!/bin/bash as the first line
@ 2012-11-25  1:07 John
  2012-11-25  2:41 ` Yichao Yu
  2012-11-25  2:42 ` Kurtis Rader
  0 siblings, 2 replies; 6+ messages in thread
From: John @ 2012-11-25  1:07 UTC (permalink / raw)
  To: zsh-users

Been using zsh for a while now and loving it.  I ran into a problem today.  The following script errors out if run with zsh as my default shell:

#!/bin/bash
v_build() {

echo "The file is $1"
}

export -f v_build
find . -maxdepth 1 -type f | parallel v_build

Output:
% ./test 
zsh:1: command not found: v_build
zsh:1: command not found: v_build
zsh:1: command not found: v_build
zsh:1: command not found: v_build

If I switch to a user who has bash as its default shell, the same script runs just fine:

$ ./test
The file is ./test
The file is ./01.jpg
The file is ./02.jpg
The file is ./03.jpg

Love to understand what I have incorrectly configured.  It seems like zsh is ignoring the shebang telling it to use /bin/bash as the shell to run the script.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-11-25 15:09 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-11-25  1:07 zsh will not run scripts as /bin/bash even with #!/bin/bash as the first line John
2012-11-25  2:41 ` Yichao Yu
2012-11-25  4:22   ` John
2012-11-25  5:05     ` Bart Schaefer
2012-11-25 15:09       ` John
2012-11-25  2:42 ` Kurtis Rader

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).