Ross:
First, because the code itself just should be compliant with POSIX
standard. Cleaning the code is the better solution than using a more
"sloppy" interpreter. Second, the changes are small. Third, maybe at
some point someone does not have the bash... I don't know :)
Jason:
It's totally fine.. additional comments: when testing for the number of
arguments, I'd say: Only if exactly two are given, assign them to GPU_ID
and PREC_MODEL, otherwise keep the defaults. This is well-defined
behavior then. The "x" trick can make sense in longer test compounds, as
explained in this foot note:
http://tldp.org/LDP/abs/html/comparison-ops.html#FTN.AEN3638
On 11/02/2011 07:14 PM, Ross Walker wrote:
>> Thanks for the report! I recently switched away from Ubuntu on my main
>> Machine, so I don't catch bash-isms in scripts anymore. This has been
>> fixed in the developer tree for both test_amber_cuda.sh and
>> test_amber_cuda_parallel.sh. I altered it slightly to be
>>
>> if [ $# -lt 1 ]; then
>>
>
> Why not the more simple 1 line fix?
>
> #!/bin/sh ---> #!/bin/bash
>
> All the best
> Ross
>
> /\
> \/
> |\oss Walker
>
> ---------------------------------------------------------
> | Assistant Research Professor |
> | San Diego Supercomputer Center |
> | Adjunct Assistant Professor |
> | Dept. of Chemistry and Biochemistry |
> | University of California San Diego |
> | NVIDIA Fellow |
> | http://www.rosswalker.co.uk | http://www.wmd-lab.org/ |
> | Tel: +1 858 822 0854 | EMail:- ross.rosswalker.co.uk |
> ---------------------------------------------------------
>
> Note: Electronic Mail is not secure, has no guarantee of delivery, may not
> be read every day, and should not be used for urgent or sensitive issues.
>
>
>
>
>
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org
> http://lists.ambermd.org/mailman/listinfo/amber
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Wed Nov 02 2011 - 11:30:04 PDT