File: preinst

package info (click to toggle)
ikiwiki 2.53.6
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 5,420 kB
  • ctags: 740
  • sloc: perl: 11,581; python: 353; sh: 99; makefile: 83
file content (16 lines) | stat: -rwxr-xr-x 314 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh

#DEBHELPER#

if [ "$1" = upgrade ] && dpkg --compare-versions "$2" lt 1.2; then
	if [ -e /etc/wikilist ]; then
		if [ ! -e /etc/ikiwiki/wikilist ]; then
			if [ ! -e /etc/ikiwiki ]; then
				mkdir /etc/ikiwiki
			fi
			mv -f /etc/wikilist /etc/ikiwiki/wikilist
		else
			rm -f /etc/wikilist
		fi
	fi
fi