This file is indexed.

postinst is in elmer 6.1.0.svn.5396.dfsg-2ubuntu1.

This file is a maintainer script. It is executed when installing (*inst) or removing (*rm) the package.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
#! /bin/sh -e 

PROVIDED_MODELS="helmholtz navier-stokes resultoutput heatequation linearelasticity k-epsilon meshdeform advection-diffusion elasticplate electrostatics freesurface poissonboltzmann reynolds saveline savescalars statcurrent"

# Load debconf
. /usr/share/debconf/confmodule

# Get selected models into \n-separated list
db_get elmer/models
SELECTED_MODELS="$(echo $RET | sed -e 's/, / /g')"

# Remove old symlinks, if any
for model in $PROVIDED_MODELS; do
    rm -f /usr/share/ElmerGUI/edf/$model.xml;
done

# Make new symlinks
for model in $SELECTED_MODELS; do
    ln -s ../edf-extra/$model.xml /usr/share/ElmerGUI/edf/$model.xml
done