This file is indexed.

preinst is in python-foolscap 0.13.1-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
#!/bin/sh
set -e

# there are no guarantees on unpack order, so when the pyshared egg
# folder is extracted before the symlinks in /usr/lib/.../dist-packages
# the upgrade will fail due to policy 6.6.4  when there are more than
# one supported python version as it will try to overwrite a directory
# after following the symlink
# => remove egg symlink installed by 0.6.1-1 before unpacking
if [ "$1" = upgrade ] && dpkg --compare-versions "$2" lt "0.6.1-4"; then
  for f in /usr/lib/python2.*; do
    # if egg is a link and not pointing to a directory
    if [ -L "$f/dist-packages/foolscap-0.6.1.egg-info" ] &&
       [ -f "$f/dist-packages/foolscap-0.6.1.egg-info" ]; then
      rm -f "$f/dist-packages/foolscap-0.6.1.egg-info";
    fi
  done
fi