Sundag 17. april 2011 skreiv Taco Hoekwater:
What you would want to do is change bash to sh, and ensure that all the scripts follows the POSIX standard 100%. Then it will work in both bash, dash, ksh and any other POSIX-compatible shells.
Everything except 'sh', then ? ;)
Well, I doubt the orginal Bourne shell from 1977 is POSIX compatible. ;-) But the POSIX standard actually defines the name of the shell utility ‘sh’, so all POSIX-compatible must have a ‘sh’. It may not be placed in /usr/bin, of course, though on most sane platforms it is. :) If you *really* want to be general, you can use the POSIX command command -v sh to find it. (No, don’t use ‘which’; it is not POSIX, and will only work if the command is an application, not a built-in.) -- Karl Ove Hufthammer http://huftis.org/ Jabber: karl@huftis.org