view debian/update-dccmaps @ 2:f6716cb00029

Replace buggy stuff in deb dir, never make phone calls while working
author Peter Gervai <grin@grin.hu>
date Tue, 10 Mar 2009 14:29:12 +0100
parents
children
line wrap: on
line source

#!/bin/sh
#
# (c) 2004 by Martin Zobel-Helas
# this piece of code is published under the
# GNU General Public License


set -e
echo -n "Updating DCC map"
if [ -e /etc/dcc/map.txt ]; then
	if [ -e /var/lib/dcc/map ]; then
		rm -f /var/lib/dcc/map
		/usr/bin/cdcc -qh /var/lib/dcc 'new map; load -; info' < /etc/dcc/map.txt > /dev/null
		chown dcc:dcc /var/lib/dcc/map
		chmod 0600 /var/lib/dcc/map
	else
		/usr/bin/cdcc -qh /var/lib/dcc 'new map; load -; info' < /etc/dcc/map.txt > /dev/null
		chown dcc:dcc /var/lib/dcc/map
		chmod 0600 /var/lib/dcc/map
	fi
fi
echo "."