Files
openfoam/etc/config.csh/aliases
Mark Olesen 110b00f048 ENH: improved handling of gmp/mpfr library settings (issue #674)
- export library path for gmp/mpfr from CGAL config files.
  This is required when non-system gmp/mpfr libraries are being
  used, but not using a ThirdParty compiler installation.

- automatically handle lib/ vs lib64/ (eg, for central installations)
  for packages such as boost, CGAL, etc. While the ThirdParty
  compilation of these will normally land in lib64/, this may not be
  the case when they are supplied by another means.

- reworked the handling of foamEtcFile and foamCleanPath for less
  clutter in the configuration files.
  Added the bin/tools/lib-dir script to handle logic that is
  too complex to easily manage in csh.
2018-01-11 01:30:23 +01:00

71 lines
2.2 KiB
Bash

#----------------------------------*-sh-*--------------------------------------
# ========= |
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
# \\ / O peration |
# \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
# \\/ M anipulation | Copyright (C) 2017-2018 OpenCFD Ltd.
#------------------------------------------------------------------------------
# License
# This file is part of OpenFOAM, licensed under GNU General Public License
# <http://www.gnu.org/licenses/>.
#
# File
# etc/config.csh/aliases
# - sourced by OpenFOAM-*/etc/cshrc (or from the user's ~/.cshrc)
#
# Description
# Aliases for working with OpenFOAM
#
#------------------------------------------------------------------------------
# Change compiled version aliases
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
alias wmSet 'source $WM_PROJECT_DIR/etc/cshrc'
alias wmInt32 'wmSet WM_LABEL_SIZE=32'
alias wmInt64 'wmSet WM_LABEL_SIZE=64'
alias wmSP 'wmSet WM_PRECISION_OPTION=SP'
alias wmDP 'wmSet WM_PRECISION_OPTION=DP'
# Clear env
alias wmUnset 'source $WM_PROJECT_DIR/etc/config.csh/unset'
# Toggle wmakeScheduler on/off
# - also need to set WM_HOSTS
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
alias wmSchedOn 'setenv WM_SCHEDULER $WM_PROJECT_DIR/wmake/wmakeScheduler'
alias wmSchedOff 'unsetenv WM_SCHEDULER'
# Change directory aliases
# ~~~~~~~~~~~~~~~~~~~~~~~~
alias foam 'cd $WM_PROJECT_DIR'
alias src 'cd $FOAM_SRC'
alias lib 'cd $FOAM_LIBBIN'
alias app 'cd $FOAM_APP'
alias sol 'cd $FOAM_SOLVERS'
alias util 'cd $FOAM_UTILITIES'
alias tut 'cd $FOAM_TUTORIALS'
alias run 'cd $FOAM_RUN'
# Refresh the environment
# ~~~~~~~~~~~~~~~~~~~~~~~
alias wmRefresh 'set wmProjectDir=$WM_PROJECT_DIR; set foamSettings=$FOAM_SETTINGS; wmUnset; source $wmProjectDir/etc/cshrc $foamSettings'
# Change OpenFOAM version
# ~~~~~~~~~~~~~~~~~~~~~~~
alias foamVersion \
'if ( "\!*" != "" ) source $FOAM_INST_DIR/OpenFOAM-\!*/etc/cshrc; foam; echo OpenFOAM-$WM_PROJECT_VERSION'
# Change ParaView version
# ~~~~~~~~~~~~~~~~~~~~~~~
alias foamPV \
'source $WM_PROJECT_DIR/etc/config.csh/paraview ParaView_VERSION=\!*; echo ${ParaView_DIR:t}'
#------------------------------------------------------------------------------