vdr/vdr/debian vdr.postinst
Thomas Schmidt
pkg-vdr-dvb-changes@lists.alioth.debian.org
Sat, 13 Nov 2004 23:08:19 +0000
Update of /cvsroot/pkg-vdr-dvb/vdr/vdr/debian
In directory haydn:/tmp/cvs-serv18647/vdr/vdr/debian
Modified Files:
vdr.postinst
Log Message:
* create /var/lib/video or /var/lib/video.00 as symlink, depending on the existance of /var/lib/video (still need to test this - will be done tomorrow)
Index: vdr.postinst
===================================================================
RCS file: /cvsroot/pkg-vdr-dvb/vdr/vdr/debian/vdr.postinst,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- vdr.postinst 17 Jul 2004 12:00:47 -0000 1.9
+++ vdr.postinst 13 Nov 2004 23:08:17 -0000 1.10
@@ -58,7 +58,7 @@
gzip -dc /usr/share/doc/vdr/examples/channels.conf.terr.gz > /var/lib/vdr/channels.conf
chmod 644 /var/lib/vdr/channels.conf
;;
- Cable)
+ Cable)
gzip -dc /usr/share/doc/vdr/examples/channels.conf.cable.gz > /var/lib/vdr/channels.conf
chmod 644 /var/lib/vdr/channels.conf
;;
@@ -74,14 +74,26 @@
fi
fi
- # check if /var/lib/video should be created
- if [ ! -e /var/lib/video ]; then
- db_get vdr/create_video_dir
- if $RET; then
- mkdir /var/lib/video
+ db_get vdr/create_video_dir
+ if $RET; then
+ # check if an old directory /var/lib/video exists, and
+ # symlink it to /var/lib/video.00
+ if [ -d /var/lib/video ] && [ ! -e /var/lib/video.00 ]; then
+ ln -s video /var/lib/video.00
fi
- fi
+ # create /var/lib/video.00 if it does not exist
+ if [ ! -e /var/lib/video.00 ]; then
+ mkdir /var/lib/video.00
+ fi
+
+ # check if /var/lib/video.00 exists and /var/lib/video is
+ # missing, then create the symlink /var/lib/video which
+ # points to /var/lib/video.00
+ if [ ! -e /var/lib/video ] && [ -e /var/lib/video.00 ]; then
+ ln -s video.00 /var/lib/video
+ fi
+ fi
;;
abort-upgrade|abort-remove|abort-deconfigure)