mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
STYLE: use '&&', '||' instead of '-a' and '-o' for some shell commands
This commit is contained in:
@ -49,7 +49,7 @@ then
|
|||||||
# outside of ThirdParty and should be added to the path.
|
# outside of ThirdParty and should be added to the path.
|
||||||
|
|
||||||
ending="${ADIOS_ARCH_PATH##*-}"
|
ending="${ADIOS_ARCH_PATH##*-}"
|
||||||
if [ "$ending" != none -a "$ending" != system ]
|
if [ "$ending" != none ] && [ "$ending" != system ]
|
||||||
then
|
then
|
||||||
# PATH was already cleaned by etc/bashrc caller
|
# PATH was already cleaned by etc/bashrc caller
|
||||||
_foamAddPath $ADIOS_ARCH_PATH/bin
|
_foamAddPath $ADIOS_ARCH_PATH/bin
|
||||||
|
|||||||
@ -105,7 +105,7 @@ then
|
|||||||
foamVar_end="${1##*-}"
|
foamVar_end="${1##*-}"
|
||||||
|
|
||||||
# Do not add (none) or a system directory
|
# Do not add (none) or a system directory
|
||||||
if [ -z "$foamVar_prefix" -o "$foamVar_end" = none -o "$foamVar_end" = system ]
|
if [ -z "$foamVar_prefix" ] || [ "$foamVar_end" = none ] || [ "$foamVar_end" = system ]
|
||||||
then
|
then
|
||||||
unset foamVar_prefix foamVar_end
|
unset foamVar_prefix foamVar_end
|
||||||
return 1
|
return 1
|
||||||
|
|||||||
@ -53,7 +53,7 @@ then
|
|||||||
# outside of ThirdParty and must be added to the lib-path.
|
# outside of ThirdParty and must be added to the lib-path.
|
||||||
|
|
||||||
ending="${GPERFTOOLS_ARCH_PATH##*-}"
|
ending="${GPERFTOOLS_ARCH_PATH##*-}"
|
||||||
if [ "$ending" != none -a "$ending" != system ]
|
if [ "$ending" != none ] && [ "$ending" != system ]
|
||||||
then
|
then
|
||||||
_foamAddLib $GPERFTOOLS_ARCH_PATH/lib$WM_COMPILER_LIB_ARCH
|
_foamAddLib $GPERFTOOLS_ARCH_PATH/lib$WM_COMPILER_LIB_ARCH
|
||||||
_foamAddPath $GPERFTOOLS_ARCH_PATH/bin
|
_foamAddPath $GPERFTOOLS_ARCH_PATH/bin
|
||||||
|
|||||||
@ -204,7 +204,7 @@ case "$ParaView_VERSION" in
|
|||||||
echo " PV_PLUGIN_PATH : $PV_PLUGIN_PATH" 1>&2
|
echo " PV_PLUGIN_PATH : $PV_PLUGIN_PATH" 1>&2
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
if [ "$FOAM_VERBOSE" -a "$PS1" ]
|
if [ -n "$FOAM_VERBOSE" ] && [ -n "$PS1" ]
|
||||||
then
|
then
|
||||||
echo "No paraview found" 1>&2
|
echo "No paraview found" 1>&2
|
||||||
echo " ParaView_DIR : $ParaView_DIR" 1>&2
|
echo " ParaView_DIR : $ParaView_DIR" 1>&2
|
||||||
|
|||||||
@ -146,7 +146,7 @@ export FOAM_LIBBIN="$WM_PROJECT_DIR/platforms/$WM_OPTIONS/lib"
|
|||||||
siteDir="$WM_PROJECT_DIR/site"
|
siteDir="$WM_PROJECT_DIR/site"
|
||||||
|
|
||||||
# User override
|
# User override
|
||||||
if [ -d "$WM_PROJECT_SITE" -a "$WM_PROJECT_SITE" != "$siteDir" ]
|
if [ -d "$WM_PROJECT_SITE" ] && [ "$WM_PROJECT_SITE" != "$siteDir" ]
|
||||||
then
|
then
|
||||||
siteDir="$WM_PROJECT_SITE"
|
siteDir="$WM_PROJECT_SITE"
|
||||||
export WM_PROJECT_SITE
|
export WM_PROJECT_SITE
|
||||||
|
|||||||
Reference in New Issue
Block a user