From ac3d398811aa756be872c782f869fdd29055990b Mon Sep 17 00:00:00 2001 From: JayPiKay Date: Wed, 2 Oct 2019 08:52:45 +0200 Subject: [PATCH] Documenting cli tool --- source/conf.py | 1 + source/index.rst | 5 +++-- source/sbeam.rst | 10 ++++++++++ src/sbeam.py | 11 ----------- 4 files changed, 14 insertions(+), 13 deletions(-) create mode 100644 source/sbeam.rst diff --git a/source/conf.py b/source/conf.py index bd33b76..556094c 100644 --- a/source/conf.py +++ b/source/conf.py @@ -37,6 +37,7 @@ extensions = [ 'sphinx.ext.autodoc', 'sphinx.ext.todo', 'sphinx.ext.napoleon', + 'sphinx_click.ext', ] # Add any paths that contain templates here, relative to this directory. diff --git a/source/index.rst b/source/index.rst index 4c501bf..00a1c90 100644 --- a/source/index.rst +++ b/source/index.rst @@ -3,13 +3,14 @@ You can adapt this file completely to your liking, but it should at least contain the root `toctree` directive. -Welcome to SuperBeam CLI's documentation! -========================================= +Welcome to SuperBeam documentation! +=================================== .. toctree:: :maxdepth: 2 :caption: Contents: + sbeam SuperBeam SuperBeam.RequestHandlers diff --git a/source/sbeam.rst b/source/sbeam.rst new file mode 100644 index 0000000..3ea9a83 --- /dev/null +++ b/source/sbeam.rst @@ -0,0 +1,10 @@ +SuperBeam CLI Tool +================== + +SuperBeam CLI provides an interface to serve and receive files to and from +SuperBeam clients. The SuperBeam CLI supports the native Android application. + +.. click:: sbeam:cli + :prog: sbeam + :show-nested: + diff --git a/src/sbeam.py b/src/sbeam.py index bec7a26..2fc3c08 100755 --- a/src/sbeam.py +++ b/src/sbeam.py @@ -150,14 +150,3 @@ def tui(): if __name__ == '__main__': cli() - # to_download = 0 - # superlist = get_superlist() - # try: - # for item in superlist: - # to_download += int(item.split('||')[1]) - # except IndexError: - # print(f'Download stream contains {len(superlist) - 1} items.') - # finally: - # print(f'Target download size is {to_download} bytes.') - # save_stream('data.gz') - # split_stream('data.gz', 'received', superlist)