aboutsummaryrefslogtreecommitdiff
path: root/darwin-bootstrap/DEBIAN/postrm
diff options
context:
space:
mode:
Diffstat (limited to 'darwin-bootstrap/DEBIAN/postrm')
-rwxr-xr-xdarwin-bootstrap/DEBIAN/postrm16
1 files changed, 16 insertions, 0 deletions
diff --git a/darwin-bootstrap/DEBIAN/postrm b/darwin-bootstrap/DEBIAN/postrm
new file mode 100755
index 0000000..5eec6f8
--- /dev/null
+++ b/darwin-bootstrap/DEBIAN/postrm
@@ -0,0 +1,16 @@
+#!/bin/bash
+
+# for now, always reboot on install/uninstall
+
+# <- http://iphonedevwiki.net/index.php/Packaging#Telling_Cydia_to_respring.2Freboot_etc._after_install
+function finish() {
+ f="${1}"
+ [[ -z "${f}" || -z "${CYDIA}" ]] && return
+ cydia=(${CYDIA})
+ [[ ${cydia[1]} -eq 1 ]] || return
+ echo "finish:${f}" >&${cydia[0]}
+}
+
+if [[ "$1" == "remove" ]]; then
+ finish reboot
+fi