mirror of
https://github.com/TinyTapeout/tt-support-tools.git
synced 2026-11-03 04:36:09 +01:00
feat(tt_tool): add --print-top-module argument
This commit is contained in:
@@ -375,6 +375,9 @@ class Project:
|
|||||||
def print_wokwi_id(self):
|
def print_wokwi_id(self):
|
||||||
print(self.wokwi_id)
|
print(self.wokwi_id)
|
||||||
|
|
||||||
|
def print_top_module(self):
|
||||||
|
print(self.top_module)
|
||||||
|
|
||||||
def fetch_wokwi_files(self):
|
def fetch_wokwi_files(self):
|
||||||
logging.info("fetching wokwi files")
|
logging.info("fetching wokwi files")
|
||||||
src_file = self.src_files[0]
|
src_file = self.src_files[0]
|
||||||
|
|||||||
@@ -57,6 +57,12 @@ if __name__ == "__main__":
|
|||||||
action="store_const",
|
action="store_const",
|
||||||
const=True,
|
const=True,
|
||||||
)
|
)
|
||||||
|
parser.add_argument(
|
||||||
|
"--print-top-module",
|
||||||
|
help="prints the name of the top module",
|
||||||
|
action="store_const",
|
||||||
|
const=True,
|
||||||
|
)
|
||||||
|
|
||||||
# documentation
|
# documentation
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
@@ -134,6 +140,9 @@ if __name__ == "__main__":
|
|||||||
if args.print_wokwi_id:
|
if args.print_wokwi_id:
|
||||||
project.print_wokwi_id()
|
project.print_wokwi_id()
|
||||||
|
|
||||||
|
if args.print_top_module:
|
||||||
|
project.print_top_module()
|
||||||
|
|
||||||
if args.create_user_config:
|
if args.create_user_config:
|
||||||
project.create_user_config()
|
project.create_user_config()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user