5
if [ "$1" = purge ]; then
6
rm -f /etc/apt/apt-build.conf
5
if [ "$1" = purge ] ; then
6
rm -f /etc/apt/apt-build.conf
8
# prepare APT and apt-build information
9
eval $(apt-config shell etcdir Dir::Etc)
10
eval $(apt-config shell sourceslist Dir::Etc::sourcelist)
11
eval $(apt-config shell sourcesparts Dir::Etc::sourceparts)
12
sourceslist=/"$etcdir""$sourceslist"
13
sourcesparts=/"$etcdir""$sourcesparts"
14
aptbuildsource="$sourcesparts"/apt-build.list
16
## remove repository directory if it is empty
17
#db_get apt-build/repository_dir
18
#repository_dir="$RET"
19
#if [ $(zcat "$repository_dir"/Packages.gz | wc -l) -eq 0 ] ; then
20
# rm -rf "$repository_dir"
23
## remove build directory if it is empty
24
#db_get apt-build/build_dir
26
#if [ -d "$build_dir" ] && [ ! $(ls -A "$build_dir") ] ; then
30
# remove apt-build.list resource file
31
if [ -f "$aptbuildsource" ] ; then
32
rm -f "$aptbuildsource"
36
# remove obsolete config file from apt-build <= 0.12.37
37
if dpkg-maintscript-helper supports rm_conffile 2>/dev/null ; then
38
dpkg-maintscript-helper rm_conffile /etc/apt/sources.list.d/apt-build -- "$@"