From da02104cf82e8b3c6f0a3d6c6a690a566cbd384c Mon Sep 17 00:00:00 2001 From: hummypkg Date: Sun, 15 Jan 2017 15:32:16 +0000 Subject: [PATCH] schema update --- CONTROL/control | 2 +- CONTROL/postinst | 15 ++++++++++++++- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/CONTROL/control b/CONTROL/control index efc6f33..489fc8f 100644 --- a/CONTROL/control +++ b/CONTROL/control @@ -1,7 +1,7 @@ Package: sweeper Priority: optional Section: misc -Version: 2.1.5-2 +Version: 2.1.5-3 Architecture: mipsel Maintainer: af123@hummypkg.org.uk Depends: webif(>=1.3.5-3) diff --git a/CONTROL/postinst b/CONTROL/postinst index 9a6e5cb..8edd329 100755 --- a/CONTROL/postinst +++ b/CONTROL/postinst @@ -31,9 +31,22 @@ case $schema in sed -e 's/^folder /& series "" /' -i "$f" done ;; + 1|2) + # Upgrade fflag arguments + echo "Upgrading sweeper rules for folder flags" + (echo /mod/etc/sweeper.conf; find /media -follow -name .sweeper) \ + | while read f; do + [ -f "$f" ] || continue + echo "Processing $f..." + sed -e ' + s/fflag autoshrinkr/fflag autoshrinkR/ + s/fflag autodecryptr/fflag autodecryptR/ + ' -i "$f" + done + ;; esac -echo 2 > /mod/.swschema +echo 3 > /mod/.swschema exit 0