File: 01setup

package info (click to toggle)
apt-setup 1%3A0.53%2Bsqueeze2
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 2,032 kB
  • ctags: 17
  • sloc: sh: 982; makefile: 2
file content (14 lines) | stat: -rwxr-xr-x 305 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh
set -e

file="$1"

# add old file as comments
sed 's/^/# /' < $ROOT/etc/apt/sources.list | sed 's/^# # */# /' > $file

# start out with old configuration, if any
if [ -e $ROOT/etc/apt/apt.conf ]; then
	cp -a $ROOT/etc/apt/apt.conf $ROOT/etc/apt/apt.conf.new
else
	>$ROOT/etc/apt/apt.conf.new
fi