This file is indexed.

postinst is in cpl-plugin-uves-calib 5.8.2+dfsg-1.

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
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/bin/sh

#set -o pipefail

PIPELINE=uves
VERSION=5.8.2

CALIB=${PIPELINE}-calib-${VERSION}
COMPONENTS="${CALIB}/cal"
TARGETDIR="/usr/share/cpl-plugins/${PIPELINE}-${VERSION}"

downloaded=0

if [ "$1" = "configure" ] ; then
    mkdir -p ${TARGETDIR}

    for suffix in "" $(seq -f -%.0f 1 9) ; do

	KIT=${PIPELINE}-kit-${VERSION}${suffix}
	URL=ftp://ftp.eso.org/pub/dfs/pipelines/${PIPELINE}/${KIT}.tar.gz
	TAR=${KIT}/${CALIB}.tar.gz

	wget -O- ${URL} | \
	    tar xzO ${TAR} | \
	    tar xzC ${TARGETDIR} ${COMPONENTS} --strip-components=1

	if [ $? = 0 ] ; then
	    downloaded=1
	    break
	fi
    done
fi

if [ $downloaded = 0 ] ; then
    exit 1
fi

set -e