[FGS] build_si error?

Frank Warmerdam warmerdam at pobox.com
Tue Jul 10 11:52:58 EDT 2007


Daniel Morissette wrote:
> Frank Warmerdam wrote:
>>
>> I would like to change list_module_dep.sh and similar scripts to
>> report errors to stderr (file descriptor 2) like this:
>>
>> echo "! Module '$MODULE_NAME' doesn't have VERSION file 
>> '$FGS_MODULES_HOME/$MODULE_NAME/etc/fgs/pkgs/$MODULE_NAME/VERSION'" >&2
>>
>> That way the error messages are reported and the return code indicates
>> failure.  Is there any objection to such a change?
>>
> 
> Sounds like a good idea to me.

Daniel,

Change applied in cvs, but only to the list_module_dep.sh script.  A similar
approach might be appropriate in other locations too, but I don't understand
how things fit together well enough to be confident.  In particular if we
direct some messages through stdout and some through stderr the order can
get mixed up, so it is likely best to only use stderr where we expect a
script or bash function is going to be called by other scripts that
capture stdout for use.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | President OSGeo, http://osgeo.org



More information about the Foss-gis-suite mailing list