A telegram bot to find the nearest lighthouse. You will be asked to choose the country and state and then your location. Bot will then send you the location of the lighthouse nearest to you. Currently supported Kerala/India only.
-
Download or pull this source code to the desired path.
-
Move to the root directory of this codebase. (To Where the script
lighhouse_bot.py
is). -
Create a virtual environment and activate it, if required.
$ python -m venv /DESIRED/PATH/TO/YOUR/VENV $ source /DESIRED/PATH/TO/YOUR/VENV/bin/activate
-
Install the dependencies:
$ pip install -r requirements.txt
-
Create a
.env
file there with the following content:TELEGRAM_TOKEN="REPLACE_THIS_STRING_WITH_YOUR_ACTUAL_TOKEN"
-
Create a
.data
directory and copy data files,lighthouses.json
andcountries.json
, there. -
Run the script,
lighthouse_bot.py
now:$ python lighthouse_bot.py