vinaigrette/scripts/pbuilder/hooks/E01apt-preferences

17 lines
427 B
Text
Raw Normal View History

2017-09-04 19:13:28 +02:00
#!/bin/sh
set -e
if $(cat "/etc/apt/sources.list" | grep -q "wheezy-backports"); then
echo "Adding pin preferences for wheezy-backports"
cat > "/etc/apt/preferences.d/wheezy-backports" << EOF
Package: dh-python dh-systemd devscripts
Pin: release a=wheezy-backports
Pin-Priority: 999
EOF
else
if [ -f /etc/apt/preferences.d/wheezy-backports ]; then
rm -vf /etc/apt/preferences.d/wheezy-backports
fi
fi