> I don't want to use zsh specific features in my scripts
How is this a worry?
The topline in your bash script is '#!/bin/bash'
Which tells the system 'run this with bash'.
How is this a worry?
The topline in your bash script is '#!/bin/bash'
Which tells the system 'run this with bash'.
Example, I _think_ / (recursive globbing) works by default in zsh but not in bash. If you have / in a bash script without setting the right options then your script won't work and you will have no idea why until you've wasted a lot of time debugging.
#!/bin/bash
The specified program is run. From that point on, the bits you're executing in that script are 'bash' no matter what the shell you called it from is.I've been running zsh on my local system, and happily writing [bash, csh, perl, ruby] using this trick.