Skip to content

Commit

Permalink
refactor(main.py): added an entrypoint to run the program
Browse files Browse the repository at this point in the history
this is necessary in order to create a binary using pyinstaller
  • Loading branch information
lewoudar committed Jan 14, 2024
1 parent c8aa6d9 commit c94bf42
Showing 1 changed file with 12 additions and 8 deletions.
20 changes: 12 additions & 8 deletions ws/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
from click_didyoumean import DYMGroup
from rich.traceback import install

from .commands.completion import install_completion
from .commands.echo_server import echo_server
from .commands.listen import listen
from .commands.ping import ping
from .commands.pong import pong
from .commands.session import session
from .commands.tail import tail
from .commands.text_byte import byte, text
from ws.commands.completion import install_completion
from ws.commands.echo_server import echo_server
from ws.commands.listen import listen
from ws.commands.ping import ping
from ws.commands.pong import pong
from ws.commands.session import session
from ws.commands.tail import tail
from ws.commands.text_byte import byte, text

install(show_locals=True)

Expand Down Expand Up @@ -38,3 +38,7 @@ def cli():

for command in [tail, ping, pong, echo_server, listen, byte, text, install_completion, session]:
cli.add_command(command)


if __name__ == '__main__':
cli()

0 comments on commit c94bf42

Please sign in to comment.