aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortoni <matzeton@googlemail.com>2014-04-21 14:20:58 +0200
committertoni <matzeton@googlemail.com>2014-04-21 14:20:58 +0200
commit56b1254b95ccacba785700fddac212289854356a (patch)
treeeb7d31c4c0127921f65fb2ebcc7ce9cf0737bcfa
parent9f73bf7716a95dd5ef642f89cd736cec50096fa5 (diff)
added activate/deactivate feature (5)
-rw-r--r--debian/postinst7
1 files changed, 4 insertions, 3 deletions
diff --git a/debian/postinst b/debian/postinst
index a99233b..675f783 100644
--- a/debian/postinst
+++ b/debian/postinst
@@ -34,8 +34,10 @@ case "$1" in
active=1
text="active. Deactivate?"
fi
- whiptail --yesno "naskpass is $text" --yes-button "Yes" --no-button "No" 10 70
+ set +e
+ whiptail --yesno "naskpass is $text" --defaultno 10 70
choice=$?
+ set -e
case ${choice} in
0)
if [ ${active} -eq 0 ]; then
@@ -53,11 +55,10 @@ case "$1" in
1)
echo "Keeping naskpass' status .." >&2
;;
- -1|*)
+ *)
echo "Unknown whiptail error occured .." >&2
;;
esac
- update-initramfs -u
;;
upgrade)