<br>Maybe <br><br>#!/usr/bin/env bash <br><br>instead of<br><br>#!/bin/bash<br><br>will solve the uncertainities of localization<br><br><br><div><span class="gmail_quote">2007/2/21, Glynn Clements &lt;<a href="mailto:glynn@gclements.plus.com">
glynn@gclements.plus.com</a>&gt;:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>Hamish wrote:<br><br>&gt; 2) keep #!/bin/sh, but add this within the script:
<br>&gt;<br>&gt; if [ -z &quot;$BASH&quot; ] ; then<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;echo &quot;$0: This script requires Bash.&quot; 1&gt;&amp;2<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;exit 1<br>&gt; fi<br><br>Or:<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if [ -z &quot;$BASH&quot; ] ; then<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;exec bash &quot;$0&quot; &quot;$@&quot;
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo &quot;$0: This script requires Bash.&quot; 1&gt;&amp;2<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;exit 1<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;fi<br><br>AFAICT, that should work so long as bash is called &quot;bash&quot; (and not<br>e.g. &quot;bash2&quot; or &quot;
bash-3.1.17&quot;) and is somewhere in the path.<br><br>--<br>Glynn Clements &lt;<a href="mailto:glynn@gclements.plus.com">glynn@gclements.plus.com</a>&gt;<br><br>_______________________________________________<br>grass-dev mailing list
<br><a href="mailto:grass-dev@grass.itc.it">grass-dev@grass.itc.it</a><br><a href="http://grass.itc.it/mailman/listinfo/grass-dev">http://grass.itc.it/mailman/listinfo/grass-dev</a><br></blockquote></div><br>