#!/bin/bash

set -e

if [[ "${is_minimal}" = "true" ]]; then
    return 0
elif [[ "${is_ghost}" = "true" ]]; then
    return 0
fi

if [[ "${is_audit_mode}" == "true" ]]; then
    if [[ -f /target/etc/apt/sources.list ]]; then
    	cp -a /target/etc/apt/sources.list /target/etc/apt/sources.list.ple
    fi
fi


if [[ -f /target/etc/apt/sources.list.bak ]]; then
    mv /target/etc/apt/sources.list{.bak,}
fi
