diff --git a/__init__.py b/__init__.py new file mode 100644 index 0000000..e456109 --- /dev/null +++ b/__init__.py @@ -0,0 +1,19 @@ +"""Init for the baconscript package.""" + +from .bacon import ( + HogNet, + beautify_lisp_string, + OscCommentMacroListener, + SyntaxErrorListener, + load_config, + comment, +) + +__all__ = [ + "HogNet", + "beautify_lisp_string", + "OscCommentMacroListener", + "SyntaxErrorListener", + "load_config", + "comment", +] diff --git a/bacon/OscListener.py b/bacon/OscListener.py index 0aba160..b5f2b78 100644 --- a/bacon/OscListener.py +++ b/bacon/OscListener.py @@ -6,6 +6,10 @@ from time import sleep from .commentmacro.CommentMacroParser import CommentMacroParser from .commentmacro.CommentMacroListener import CommentMacroListener +__all__ = [ + "beautify_lisp_string", + "OscCommentMacroListener", +] # https://raw.githubusercontent.com/jszheng/py3antlr4book/master/bin/pygrun # this is a python version of TestRig diff --git a/bacon/__init__.py b/bacon/__init__.py index 51a23f9..2496720 100644 --- a/bacon/__init__.py +++ b/bacon/__init__.py @@ -1,2 +1,20 @@ """Main BaconScript module init.""" -__all__ = ["script", "hog4", "OscListener"] + +from .hog4 import HogNet +from .OscListener import beautify_lisp_string, OscCommentMacroListener +from .script import SyntaxErrorListener, load_config, comment + +__all__ = [ + "HogNet", + ] + +__all__ += [ + "beautify_lisp_string", + "OscCommentMacroListener", + ] + +__all__ = [ + "SyntaxErrorListener", + "load_config", + "comment", + ] diff --git a/bacon/commentmacro/__init__.py b/bacon/commentmacro/__init__.py index 52c2354..d22185b 100644 --- a/bacon/commentmacro/__init__.py +++ b/bacon/commentmacro/__init__.py @@ -1,2 +1 @@ """Init for comment macro antlr4.""" -__all__ = ["CommentMacroLexer", "CommentMacroListener", "CommentMacroParser"] diff --git a/bacon/hog4.py b/bacon/hog4.py index 83cb7fa..c161dc9 100644 --- a/bacon/hog4.py +++ b/bacon/hog4.py @@ -6,6 +6,9 @@ from typing import Any, Dict, Union from pythonosc import udp_client, osc_message_builder, osc_bundle, osc_message from antlr4 import ParserRuleContext +__all__ = [ + "HogNet", +] class HogNet: """Class definition of a hognet participant.""" diff --git a/bacon/script.py b/bacon/script.py index 32f7145..b31f0c2 100644 --- a/bacon/script.py +++ b/bacon/script.py @@ -12,6 +12,11 @@ from .commentmacro.CommentMacroLexer import CommentMacroLexer from .commentmacro.CommentMacroParser import CommentMacroParser from .OscListener import OscCommentMacroListener +__all__ = [ + "SyntaxErrorListener", + "load_config", + "comment", +] class SyntaxErrorListener(ErrorListener): """An error listener that raises SyntaxError exceptions."""