From b177494abeea7ee6e686e962e1f46d0e1704bf6c Mon Sep 17 00:00:00 2001 From: Tobi Okedeji Date: Mon, 22 Apr 2024 13:08:19 +0100 Subject: [PATCH] restructure commands to take subgroups --- allocmd/cli.py | 8 +++++++- allocmd/utilities/constants.py | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/allocmd/cli.py b/allocmd/cli.py index 78b98d7..d7b8dce 100644 --- a/allocmd/cli.py +++ b/allocmd/cli.py @@ -17,11 +17,17 @@ def cli(): """A CLI Tool that handles creation of an Allora Worker Node""" pass +@cli.group() +def generate(): + """generate scaffolded files and directories depending on the type passed.""" + pass + +@generate.command() @click.command() @click.option('--env', 'environment', required=True, type=click.Choice(['dev', 'prod']), help='Environment to generate for') @click.option('--name', required=False, help='Name of the worker.') @click.option('--topic', required=False, type=int, help='The topic ID the worker is registered with.') -def init(environment, name=None, topic=None): +def worker(environment, name=None, topic=None): """Initialize your Allora Worker Node with necessary boilerplates""" if environment == 'dev': diff --git a/allocmd/utilities/constants.py b/allocmd/utilities/constants.py index bd10199..9a41826 100644 --- a/allocmd/utilities/constants.py +++ b/allocmd/utilities/constants.py @@ -1,2 +1,2 @@ -cliVersion = "0.2.5" +cliVersion = "0.2.6"