From b099f593d5227453b999271ec2f00d8e81ab5b86 Mon Sep 17 00:00:00 2001 From: Elena ``of Valhalla'' Grandi Date: Thu, 4 Aug 2022 18:08:52 +0200 Subject: Use hazwaz to generate command line commands --- scripts/lesana | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) (limited to 'scripts') diff --git a/scripts/lesana b/scripts/lesana index ed6084a..5c84d56 100755 --- a/scripts/lesana +++ b/scripts/lesana @@ -4,25 +4,27 @@ Lesana Command Line interface """ import logging +import hazwaz + import lesana.command -class Lesana(lesana.command.MainCommand): +class Lesana(hazwaz.MainCommand): """ Manage collections """ commands = ( - ("new", lesana.command.New()), - ("edit", lesana.command.Edit()), - ("show", lesana.command.Show()), - ("index", lesana.command.Index()), - ("search", lesana.command.Search()), - ("get-values", lesana.command.GetValues()), - ("update", lesana.command.Update()), - ("export", lesana.command.Export()), - ("init", lesana.command.Init()), - ("rm", lesana.command.Remove()), + lesana.command.New(), + lesana.command.Edit(), + lesana.command.Show(), + lesana.command.Index(), + lesana.command.Search(), + lesana.command.GetValues(), + lesana.command.Update(), + lesana.command.Export(), + lesana.command.Init(), + lesana.command.Remove(), ) @@ -36,4 +38,4 @@ if __name__ == "__main__": logger.addHandler(ch) logger.setLevel(logging.INFO) - Lesana().main() + Lesana().run() -- cgit v1.2.3