mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
STYLE: avoid intermediate variables when calling _foamSource (csh)
This commit is contained in:
21
etc/cshrc
21
etc/cshrc
@ -69,14 +69,10 @@ setenv WM_THIRD_PARTY_DIR $WM_PROJECT_INST_DIR/ThirdParty-$WM_PROJECT_VERSION
|
||||
|
||||
|
||||
# Source files, possibly with some verbosity
|
||||
alias _foamSource 'if ($?FOAM_VERBOSE && $?prompt) echo "Sourcing: \!*"; source \!*'
|
||||
alias _foamSource 'if ($?FOAM_VERBOSE && $?prompt) echo "Sourcing: \!*"; if (\!* != "") source \!*'
|
||||
|
||||
# Add in preset user or site preferences:
|
||||
set foamPrefs=`$WM_PROJECT_DIR/bin/foamEtcFile prefs.csh`
|
||||
if ( $status == 0 ) then
|
||||
_foamSource $foamPrefs
|
||||
endif
|
||||
unset foamPrefs
|
||||
_foamSource `$WM_PROJECT_DIR/bin/foamEtcFile prefs.csh`
|
||||
|
||||
# Evaluate command-line parameters
|
||||
while ( $#argv > 0 )
|
||||
@ -255,17 +251,8 @@ _foamSource $WM_PROJECT_DIR/etc/aliases.csh
|
||||
|
||||
# Source user setup files for optional packages
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
set paraview3=`$WM_PROJECT_DIR/bin/foamEtcFile apps/paraview3/cshrc`
|
||||
if ( $status == 0 ) then
|
||||
_foamSource $paraview3
|
||||
endif
|
||||
unset paraview3
|
||||
|
||||
set ensight=`$WM_PROJECT_DIR/bin/foamEtcFile apps/ensight/cshrc`
|
||||
if ( $status == 0 ) then
|
||||
_foamSource $ensight
|
||||
endif
|
||||
unset ensight
|
||||
_foamSource `$WM_PROJECT_DIR/bin/foamEtcFile apps/paraview3/cshrc`
|
||||
_foamSource `$WM_PROJECT_DIR/bin/foamEtcFile apps/ensight/cshrc`
|
||||
|
||||
|
||||
# Clean environment paths again. Only remove duplicates
|
||||
|
||||
Reference in New Issue
Block a user