From f6b6187298b436fb800edeb2a02af28412246fd1 Mon Sep 17 00:00:00 2001 From: "John N. Milner" Date: Thu, 30 Apr 2020 00:53:34 -0400 Subject: [PATCH] =?UTF-8?q?Accept=20either=20`--update`=20or=20`--upgrade`?= =?UTF-8?q?=E2=80=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit in preparation for 8399d8c --- helpers/command.py | 4 ++-- run.py | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/helpers/command.py b/helpers/command.py index 73c2411..66ee44d 100644 --- a/helpers/command.py +++ b/helpers/command.py @@ -33,8 +33,8 @@ def help(): " Prompt questions to rebuild configuration. Restart KoBoToolbox\n" " -S, --stop\n" " Stop KoBoToolbox\n" - " -u, --upgrade\n" - " Upgrade KoBoToolbox\n" + " -u, --update, --upgrade\n" + " Update KoBoToolbox\n" " -cf, --compose-frontend [docker-compose arguments]\n" " Run a docker-compose command in the front-end environment\n" " -cb, --compose-backend [docker-compose arguments]\n" diff --git a/run.py b/run.py index 3fca7cd..5f658cd 100755 --- a/run.py +++ b/run.py @@ -55,7 +55,11 @@ def run(force_setup=False): elif len(sys.argv) == 2: if sys.argv[1] == "-h" or sys.argv[1] == "--help": Command.help() - elif sys.argv[1] == "-u" or sys.argv[1] == "--upgrade": + elif sys.argv[1] == "-u" or sys.argv[1] == "--update": + # Gets changed to "update" in a future release; accept either + # "update" or "upgrade" here to ease the transition + Command.upgrade() + elif sys.argv[1] == "--upgrade": Command.upgrade() elif sys.argv[1] == "-i" or sys.argv[1] == "--info": Command.info(0)