Drop Latest change lines, add initial support for Debian/squeeze
[grml-live.git] / etc / grml / fai / config / scripts / GRMLBASE / 33-aptsetup
1 #!/bin/sh
2 # Filename:      /etc/grml/fai/config/scripts/GRMLBASE/33-aptsetup
3 # Purpose:       configure Debian package management of live-system
4 # Authors:       grml-team (grml.org), (c) Michael Prokop <mika@grml.org>
5 # Bug-Reports:   see http://grml.org/bugs/
6 # License:       This file is licensed under the GPL v2 or any later version.
7 ################################################################################
8
9 set -u
10 set -e
11
12 rm -f $target/etc/apt/sources.list
13
14 $ROOTCMD ln -s /etc/apt/sources.list.grml /etc/apt/sources.list
15
16 # if we have a devel-version or a daily snapshot
17 # let's activate grml-testing by default:
18 if [ -n "$GRML_NAME" -o -n "$RELEASENAME" ] ; then
19    if echo "$GRML_NAME" "$RELEASENAME" | grep -e devel -e autobuild 1>/dev/null ; then
20       sed -i 's|^#\(.*deb.*deb.grml.org.*grml-testing\)|\1|' "$target"/etc/apt/sources.list
21    fi
22 fi
23
24 #if [ -r /etc/grml/fai/files/etc/apt/preferences ] ; then
25 #   cp /etc/grml/fai/files/etc/apt/preferences $target/etc/apt/preferences
26 #fi
27
28 ## END OF FILE #################################################################
29 # vim:ft=sh expandtab ai tw=80 tabstop=4 shiftwidth=3