From 26d9f6d8a390ff04c5e17101b8c3b5061d1a1e65 Mon Sep 17 00:00:00 2001 From: TotallyNotElite <1yourexperiment@protonmail.com> Date: Sat, 19 Oct 2019 19:21:40 +0200 Subject: [PATCH] Fix bug in migration --- scripts/migrations | 4 ++-- scripts/updater | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/scripts/migrations b/scripts/migrations index da8f0543..6492f38c 100755 --- a/scripts/migrations +++ b/scripts/migrations @@ -50,7 +50,7 @@ fi if [ "$version" == 1 ]; then cfg_write $configfile version 2 - if [ -d "./build/cotire" ]; then - rm -r ./build/cotire + if [ -d "./build/CMakeFiles/cathook.dir" ]; then + rm -r ./build/CMakeFiles/cathook.dir fi fi diff --git a/scripts/updater b/scripts/updater index ca80d379..bde20c39 100755 --- a/scripts/updater +++ b/scripts/updater @@ -25,7 +25,11 @@ echo $$ > ${LOCKFILE} . ./scripts/config.shlib # Run migrations -update_channel="$(cfg_read $configfile update_channel)" +exists=true +cfg_haskey $configfile update_channel || exists=false +if [ "$exists" == true ]; then + update_channel="$(cfg_read $configfile update_channel)" +fi if [ "$update_channel" != "developer" ]; then ./scripts/migrations "$@" || exit 0 fi