diff --git a/VERSION b/VERSION index 3eefcb9..9084fa2 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.0.0 +1.1.0 diff --git a/docs/changelog.rst b/docs/changelog.rst index 74ee844..2fff74b 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -22,7 +22,7 @@ Unreleased Commits `since last release`_: -.. _`since last release`: https://github.com/rhasspy/rhasspy-hermes-app/compare/v1.0.0...HEAD +.. _`since last release`: https://github.com/rhasspy/rhasspy-hermes-app/compare/v1.1.0...HEAD Added ===== @@ -42,6 +42,17 @@ Fixed Security ======== +********************* +`1.1.0`_ - 2020-08-28 +********************* + +.. _`1.1.0`: https://github.com/rhasspy/rhasspy-hermes-app/releases/tag/v1.1.0 + +Changed +======= + +- Command-line arguments can now also be passed as keyword arguments to the constructor of a :class:`rhasspyhermes_app.HermesApp` object. Note that arguments on the command line have precedence. Pull request `#37 `_ by `@JonahKr `_ with help from `@maxbachmann `_. + ********************* `1.0.0`_ - 2020-07-26 ********************* diff --git a/docs/usage.rst b/docs/usage.rst index dc76439..3c1d8ed 100644 --- a/docs/usage.rst +++ b/docs/usage.rst @@ -32,7 +32,8 @@ Try the example app `time_app.py`_ with the ``--help`` flag to see what settings .. _`time_app.py`: https://github.com/rhasspy/rhasspy-hermes-app/blob/master/examples/time_app.py You can pass all the settings as keyword arguments inside the constructor aswell: -:meth:`HermesApp("ExampleApp", host = "192.168.178.123", port = 12183)` +:meth:`rhasspyhermes_app.HermesApp("ExampleApp", host="192.168.178.123", port=12183)`. Note that arguments passed on the +command line have precedence over arguments passed to the constructor. ******* Asyncio diff --git a/rhasspyhermes_app/__init__.py b/rhasspyhermes_app/__init__.py index d6386b9..368fe19 100644 --- a/rhasspyhermes_app/__init__.py +++ b/rhasspyhermes_app/__init__.py @@ -99,6 +99,10 @@ def __init__( mqtt_client: An MQTT client. If the argument is not specified, the object creates an MQTT client itself. + + **kwargs: Other arguments. This supports the same arguments as the command-line + arguments, such has ``host`` and ``port``. Arguments specified by the user + on the command line have precedence over arguments passed as ``**kwargs``. """ if parser is None: parser = argparse.ArgumentParser(prog=name)