Skip to content

Commit

Permalink
app: make main() in west.app.main module public API
Browse files Browse the repository at this point in the history
Added documentation to main() as it is now officially supported to
directly call main from west.app.main module.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
  • Loading branch information
tejlmand authored and mbolivar-nordic committed Jun 17, 2020
1 parent 26b69f9 commit 5843eef
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/west/app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

'''Zephyr RTOS meta-tool (west) main module
Nothing in here is public API.
Only the main() method in here is public API.
'''

import argparse
Expand Down Expand Up @@ -754,6 +754,14 @@ def dump_traceback():
return name

def main(argv=None):
'''Run the application with argument list ``argv``.
The argument list is identical to the command-line west application
arguments, see ``west help``
:param argv: argument list, the list of valid arguments can be seen by
invoking ``west help``
'''
# Silence validation errors from pykwalify, which are logged at
# logging.ERROR level. We want to handle those ourselves as
# needed.
Expand Down

0 comments on commit 5843eef

Please sign in to comment.