|
| 1 | +### Downloading |
| 2 | + |
| 3 | +#### Archive |
| 4 | +Download CloudBot from [https://github.com/TotallyNotRobots/CloudBot/zipball/gonzobot.zip](https://github.com/TotallyNotRobots/CloudBot/archive/gonzobot.zip) and unzip, or execute the following commands: |
| 5 | +```bash |
| 6 | +curl -Ls https://github.com/TotallyNotRobots/CloudBot/archive/gonzobot.zip > CloudBot.zip |
| 7 | +unzip CloudBot.zip |
| 8 | +cd CloudBot-gonzobot |
| 9 | +``` |
| 10 | + |
| 11 | +#### Git |
| 12 | + |
| 13 | +Alternately, you can also clone CloudBot by using: |
| 14 | +```bash |
| 15 | +git clone https://github.com/TotallyNotRobots/CloudBot.git |
| 16 | +cd CloudBot |
| 17 | +``` |
| 18 | + |
| 19 | +### Installing Dependencies |
| 20 | + |
| 21 | +All of CloudBot's python dependencies are stored in the `requirements.txt` file, and can be installed with pip. |
| 22 | + |
| 23 | +But first, you will need `git`, `python3.5-dev` and `libenchant1c2a`, `libxml2-dev`, `libxslt-dev` and `zlib1g-dev`. Install these with your system's package manager. |
| 24 | + |
| 25 | +For example, on a Debian-based system, you could use: |
| 26 | +```bash |
| 27 | +[sudo] apt-get install -y python3.5-dev git libenchant-dev libxml2-dev libxslt-dev zlib1g-dev |
| 28 | +``` |
| 29 | + |
| 30 | +You will also need to install `pip`, which can be done by following [this guide](https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/#installing-pip) |
| 31 | + |
| 32 | +It is also recommended that you create a virtual environment for the bot to isolate it from system library updates. First, [install the venv package](https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/#installing-virtualenv) if required, and then [create the virtual environment](https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/#creating-a-virtual-environment) |
| 33 | + |
| 34 | +We will refer to the virtual environment directory as `<VENV_DIR>` from here on. |
| 35 | + |
| 36 | +Once the virtual environment is created, [activate it](https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/#activating-a-virtual-environment). |
| 37 | + |
| 38 | +Finally, install the python dependencies using `pip` using the following command in the CloudBot directory: |
| 39 | +```bash |
| 40 | +pip install -Ur requirements.txt |
| 41 | +``` |
| 42 | + |
| 43 | +Now you are ready to run the bot! This can be done simply by executing the cloudbot module like so |
| 44 | +```bash |
| 45 | +python -m cloudbot |
| 46 | +``` |
| 47 | +or without activating the virtual environment, use |
| 48 | +```bash |
| 49 | +<VENV_DIR>/bin/python -m cloudbot |
| 50 | +``` |
0 commit comments