diff options
author | toni <matzeton@googlemail.com> | 2014-04-22 08:25:24 +0200 |
---|---|---|
committer | toni <matzeton@googlemail.com> | 2014-04-22 08:25:24 +0200 |
commit | 597e1d4918ce533a977f7214868cf00a201ace7d (patch) | |
tree | 72e6a8ac9af1c8c94df6f2912802cdaf6a8e3ad0 /debian/preinst | |
parent | 85630c7a02d90a5e1a2e317349578a66bb8b67bc (diff) |
added activate/deactivate feature (9)
Diffstat (limited to 'debian/preinst')
-rw-r--r-- | debian/preinst | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/debian/preinst b/debian/preinst index e6e374c..f50aa9f 100644 --- a/debian/preinst +++ b/debian/preinst @@ -9,9 +9,15 @@ set -e export RDSUM="5924c70e5c9fabf0398050349c3f4f283ab80091b23ea8c677249ee7bdd41f6e4910ce5e1bc32577e67763dc30d9b96cc3528256e1cc63dba959a5e3866ec21f" export ORGFILE="/usr/share/initramfs-tools/scripts/local-top/cryptroot" export DIVFILE="/usr/share/naskpass/cryptroot.orig" +export BCKFILE="/var/backups/cryptroot.naskpass" case "$1" in - install|upgrade) + upgrade) + if [ -f ${BCKFILE} ]; then + mv ${BCKFILE} ${ORGFILE} || true + fi + ;; + install) mkdir -p /usr/share/naskpass if [ ! -f ${ORGFILE} ]; then whiptail --title "Missing file" --msgbox "/usr/share/initramfs-tools/scripts/local-top/cryptroot is missing!\nabort .." 9 70 |