From c85c3cce558b32c4fb00a339872d4dbe035d3f6c Mon Sep 17 00:00:00 2001 From: Lukas Fleischer Date: Thu, 29 Mar 2012 17:06:56 +0200 Subject: Fix semantics of "general."{systemdialogs,progressbar} These were renamed from "skip_"* to *. However, we only changed syntax and didn't invert their semantic meaning. Fix this by negating the semantics of those variables. Also, negate these in the configuration file automatically when running `calcurse-upgrade`. Signed-off-by: Lukas Fleischer --- scripts/calcurse-upgrade | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'scripts') diff --git a/scripts/calcurse-upgrade b/scripts/calcurse-upgrade index c7e9691..0d9b196 100644 --- a/scripts/calcurse-upgrade +++ b/scripts/calcurse-upgrade @@ -63,5 +63,13 @@ if grep -q -e '^auto_save=' -e '^auto_gc=' -e '^periodic_save=' \ -e '/^daemon.log=/{N;s/\n//}' "$CONFFILE" > "$tmpfile" || exit 1 mv "$tmpfile" "$CONFFILE" || exit 1 fi + + awk ' + BEGIN { FS=OFS="=" } + $1 == "general.systemdialogs" || $1 == "general.progressbar" \ + { $2 = ($2 == "yes") ? "no" : "yes" } + { print } + ' < "$CONFFILE" > "$tmpfile" || exit 1 + mv "$tmpfile" "$CONFFILE" || exit 1 fi -- cgit v1.2.3-70-g09d2