From d8afea24f213d105a381c9f35cbaff04d0ecaf65 Mon Sep 17 00:00:00 2001 From: Obijuan Date: Tue, 20 Feb 2024 10:32:08 +0100 Subject: [PATCH] Bug fixed: "apio init" should show the help --- apio/commands/init.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apio/commands/init.py b/apio/commands/init.py index ed99fc69..38529a9d 100644 --- a/apio/commands/init.py +++ b/apio/commands/init.py @@ -26,7 +26,6 @@ "--top-module", type=str, metavar="top_module", - default="main", help="Set the top_module in the init file", ) @click.option( @@ -51,6 +50,9 @@ def cli(ctx, board, top_module, scons, project_dir, sayyes): if scons: Project().create_sconstruct(project_dir, "ice40", sayyes) elif board: + # -- Set the default top_module when creating the ini file + if not top_module: + top_module = "main" Project().create_ini(board, top_module, project_dir, sayyes) elif top_module: print("INIT TOP-MODULE!!")