Maledetto Bielli
is as simple as: ./biellibot.py
but that's good for testing, if you want a more consistent way to handle this use the provided bash scripts:
start.sh that will:
- start the bot
- redirect logs to
./logs/{timestamp}.log - write a PID file to
./run/biellibot.pid
stop.sh that will just kill the process in PID file.
-
install/update homebrew
-
install python3:
$ brew install python3NOTE:
pythonpoints to system installation (typically 2.7.X),python3points to homebrew installation -
configure virtual environment
$ mkdir python_envs $ cd python_envs/ $ python3 -m venv cbtranslator # activate the env: $ source python_envs/biellibot/bin/activate # deactivate the env: $ deactivateNOTE: using the created env
python --versionpoints to python3 and also does pip -
install dependencies:
$ source python_envs/biellibot/bin/activate $ cd bielli_bot/ $ pip install -r requirements.txt -
write your configuration in
settings.json. For details see template configuration file:settings.template.json
In case other dependencies are added during development, to update the requirements file run:
$ pip freeze > requirements.txt