From 9fb52c7cdb52af3be7b7c49dde67ff3ed952a816 Mon Sep 17 00:00:00 2001 From: John Burwell Date: Sun, 23 Apr 2023 22:43:30 -0500 Subject: [PATCH] add setup.py, move main.py to rsbbs.py --- README.md | 8 ++++---- main.py => rsbbs.py | 0 setup.py | 6 +++++- 3 files changed, 9 insertions(+), 5 deletions(-) rename main.py => rsbbs.py (100%) diff --git a/README.md b/README.md index 9556580..2171bfb 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ Really Simple BBS (rsbbs) implements a message board for packet radio, suitable ## Installation 1. Clone the repo to a reasonable location. -2. Run `pip install -r requirements.txt` (setup.py is not working) +2. Run `pip install -r requirements.txt` 2. Copy config.yaml.sample to config.yaml and update it. ## Usage @@ -16,7 +16,7 @@ Assuming you have `ax25d` working on your system, add something like the followi ``` [KI5QKX-10 via vhf0] -default * * * * * * * root /opt/local/rsbbs/main.py rsbbs -s %S +default * * * * * * * root /usr/local/bin/rsbbs rsbbs -s %S ``` ### Directly @@ -24,13 +24,13 @@ default * * * * * * * root /opt/local/rsbbs/main.py rsbbs -s %S You can also run it directly: ``` cd /path/to/rsbbs -python3 main.py -s URCALL +python3 rsbbs.py -s URCALL ``` ### Options ``` -usage: main.py [-h] [-d] -s CALLING_STATION [-f CONFIG_FILE] [-v] +usage: rsbbs.py [-h] [-d] -s CALLING_STATION [-f CONFIG_FILE] [-v] options: -h, --help show this help message and exit diff --git a/main.py b/rsbbs.py similarity index 100% rename from main.py rename to rsbbs.py diff --git a/setup.py b/setup.py index 04eb7a3..de16b27 100644 --- a/setup.py +++ b/setup.py @@ -35,5 +35,9 @@ setup( author_email='john@atatdotdot.com', url='https://git.b-wells.us/jmbwell/rsbbs', license=license, - packages=find_packages(exclude=('tests', 'docs')) + packages=find_packages(exclude=('tests', 'docs')), + entry_points = ''' + [console_scripts] + rsbbs=rsbbs:main + ''' )