From a2b3a33d84c97be3411bbf5bd5e735d5991dab2f Mon Sep 17 00:00:00 2001 From: Bertrand Lemasle Date: Mon, 3 Sep 2018 21:32:53 +1200 Subject: [PATCH] Version bump + write version at startup if needed --- src/Config.cpp | 6 +++++- src/config/System.h | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/Config.cpp b/src/Config.cpp index 745339e..3338e9e 100644 --- a/src/Config.cpp +++ b/src/Config.cpp @@ -51,7 +51,11 @@ namespace config { void setup() { details::read(); - //details::write(); + + if(strcasecmp_P(value.version, PSTR(VERSION))) { + strcpy_P(value.version, PSTR(VERSION)); + details::write(); + } } void save() { diff --git a/src/config/System.h b/src/config/System.h index a8ec933..6ba7ba9 100644 --- a/src/config/System.h +++ b/src/config/System.h @@ -20,7 +20,7 @@ \def VERSION Version string, only used for indicative purpose */ -#define VERSION "1.20" +#define VERSION "1.21" /**