Difference between revisions of "Typical .bashrc for ESTEL"

From SourceWiki
Jump to navigation Jump to search
 
Line 1: Line 1:
 +
This article describes a typical extract of the <code>.bashrc</code> file which is used to set one's environment. Note that it is an '''incomplete''' file. It showsn only the entries related to the TELEMAC system and is missing sections about your Fortran 90 compiler and tecplot if you are using Tecplot.
 +
 +
= How it works =
 +
The code below is self explanatory but to summarise:
 +
* The TELEMAC system is installed in <code>$HOME/systel90/</code>, as defined by the variable $SYSTEL90. '''Edit this line!'''
 +
* by default, version v5p8 is used which uses the configuration folder <code>$HOME/systel90/configv5p8/</code>
 +
* Some functions are defined:
 +
<code><pre>
 +
v5p7 -> switch to version v5p7
 +
v5p8 -> switch to version v5p8
 +
e3d  -> Goes to $HOME/systel90/estel3d/estel3d_version
 +
e2d  -> Goes to $HOME/systel90/estel2d/estel2d_version
 +
</pre></code>
  
  
Line 8: Line 21:
 
##################
 
##################
  
PATH=/path/to/systel90/bin:$PATH
+
export SYSTEL90=/path/to/systel90
 +
 
 +
PATH=$SYSTEL90/systel90/bin:$PATH
 
PATH=./:$PATH
 
PATH=./:$PATH
 
# The TELEMAC perl scripts needs ./ in $PATH
 
# The TELEMAC perl scripts needs ./ in $PATH
Line 17: Line 32:
 
# Location of config directory (defaults to v5p8)
 
# Location of config directory (defaults to v5p8)
 
# Can be overridden with the functions v5p6() and  v5p7(), see below
 
# Can be overridden with the functions v5p6() and  v5p7(), see below
SYSTELCFG=/path/to/systel90/configv5p8
+
SYSTELCFG=$SYSTEL90/systel90/configv5p8
 
export SYSTELCFG
 
export SYSTELCFG
  
TOE2D=/path/to/systel90/estel2d/estel2d_v5p8/
+
TOE2D=$SYSTEL90/systel90/estel2d/estel2d_v5p8/
TOE3D=/path/to/systel90/estel3d/estel3d_v5p8/
+
TOE3D=$SYSTEL90/systel90/estel3d/estel3d_v5p8/
TOBIEF=/path/to/systel90/bief/bief_v5p8/sources/
+
TOBIEF=$SYSTEL90/systel90/bief/bief_v5p8/sources/
TOT2D=/path/to/systel90/telemac2d/tel2d_v5p8
+
TOT2D=$SYSTEL90/systel90/telemac2d/tel2d_v5p8
TOPARALLEL=/path/to/systel90/parallel/parallel_v5p8/
+
TOPARALLEL=$SYSTEL90/systel90/parallel/parallel_v5p8/
 
 
function v5p6 ()
 
{
 
eval `change_systel_version -v v5p6`
 
}
 
  
 
function v5p7 ()
 
function v5p7 ()

Revision as of 11:01, 24 August 2007

This article describes a typical extract of the .bashrc file which is used to set one's environment. Note that it is an incomplete file. It showsn only the entries related to the TELEMAC system and is missing sections about your Fortran 90 compiler and tecplot if you are using Tecplot.

How it works

The code below is self explanatory but to summarise:

  • The TELEMAC system is installed in $HOME/systel90/, as defined by the variable $SYSTEL90. Edit this line!
  • by default, version v5p8 is used which uses the configuration folder $HOME/systel90/configv5p8/
  • Some functions are defined:
v5p7 -> switch to version v5p7
v5p8 -> switch to version v5p8
e3d  -> Goes to $HOME/systel90/estel3d/estel3d_version
e2d  -> Goes to $HOME/systel90/estel2d/estel2d_version


The code


##################
# TELEMAC SYSTEM #
##################

export SYSTEL90=/path/to/systel90

PATH=$SYSTEL90/systel90/bin:$PATH
PATH=./:$PATH
# The TELEMAC perl scripts needs ./ in $PATH
# This is _very_ bad practice but hey ... I did not write them!!

export PATH

# Location of config directory (defaults to v5p8)
# Can be overridden with the functions v5p6() and  v5p7(), see below
SYSTELCFG=$SYSTEL90/systel90/configv5p8
export SYSTELCFG

TOE2D=$SYSTEL90/systel90/estel2d/estel2d_v5p8/
TOE3D=$SYSTEL90/systel90/estel3d/estel3d_v5p8/
TOBIEF=$SYSTEL90/systel90/bief/bief_v5p8/sources/
TOT2D=$SYSTEL90/systel90/telemac2d/tel2d_v5p8
TOPARALLEL=$SYSTEL90/systel90/parallel/parallel_v5p8/

function v5p7 ()
{
	eval `change_systel_version -v v5p7`
}

function v5p8 ()
{
	eval `change_systel_version -v v5p8`
}

function e3d ()
# Takes you to the estel3d directory 
{
	cd $TOE3D
}

function e2d ()
# Takes you to the estel2d directory
{
	cd $TOE2D
}

function t2d ()
# Takes you to the telemac2d directory
{
	cd $TOT2D
}

function bief ()
# Takes you to the bief directory
{
	cd $TOBIEF
}

function parallel ()
# Takes you to the bief directory
{
	cd $TOPARALLEL
}