From 4993c5a6759fa34b53e866ccc4b6617a14376b96 Mon Sep 17 00:00:00 2001 From: palmtree5 <3577255+palmtree5@users.noreply.github.com> Date: Sun, 15 Oct 2017 18:40:57 -0800 Subject: [PATCH] [V3 Docs] Add install guides to the documentation (#1005) * [Docs] add install guides to the documentation * formatting changes --- docs/index.rst | 11 +++++++++ docs/install_centos.rst | 40 +++++++++++++++++++++++++++++++++ docs/install_debian.rst | 47 +++++++++++++++++++++++++++++++++++++++ docs/install_mac.rst | 39 ++++++++++++++++++++++++++++++++ docs/install_raspbian.rst | 39 ++++++++++++++++++++++++++++++++ docs/install_ubuntu.rst | 45 +++++++++++++++++++++++++++++++++++++ docs/install_windows.rst | 37 ++++++++++++++++++++++++++++++ 7 files changed, 258 insertions(+) create mode 100644 docs/install_centos.rst create mode 100644 docs/install_debian.rst create mode 100644 docs/install_mac.rst create mode 100644 docs/install_raspbian.rst create mode 100644 docs/install_ubuntu.rst create mode 100644 docs/install_windows.rst diff --git a/docs/index.rst b/docs/index.rst index 6b8c1ee7f..709001dd7 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -6,6 +6,17 @@ Welcome to Red - Discord Bot's documentation! ============================================= +.. toctree:: + :maxdepth: 1 + :caption: Installation Guides: + + install_windows + install_mac + install_ubuntu + install_debian + install_centos + install_raspbian + .. toctree:: :maxdepth: 2 :caption: Cog Reference: diff --git a/docs/install_centos.rst b/docs/install_centos.rst new file mode 100644 index 000000000..623a332e2 --- /dev/null +++ b/docs/install_centos.rst @@ -0,0 +1,40 @@ +.. centos install guide + +========================== +Installing Red on CentOS 7 +========================== + +--------------------------- +Installing pre-requirements +--------------------------- + +.. code-block:: none + + yum -y groupinstall development + yum -y install https://centos7.iuscommunity.org/ius-release.rpm + yum -y install yum-utils wget which python35u python35u-pip python35u-devel openssl-devel libffi-devel git opus-devel + sh -c "$(wget https://gist.githubusercontent.com/mustafaturan/7053900/raw/27f4c8bad3ee2bb0027a1a52dc8501bf1e53b270/latest-ffmpeg-centos6.sh -O -)" + +-------------- +Installing Red +-------------- + +:code:`pip3 install red-discordbot[voice]` + +---------------------- +Setting up an instance +---------------------- + +Run :code:`redbot-setup` and follow the prompts. It will ask first for where you want to +store the data (the default is :code:`~/.local/share/Red-DiscordBot`) and will then ask +for confirmation of that selection. Next, it will ask you to choose your storage backend +(the default here is JSON). It will then ask for a name for your instance. This can be +anything as long as it does not contain spaces; however, keep in mind that this is the +name you will use to run your bot, and so it should be something you can remember. + +----------- +Running Red +----------- + +Run :code:`redbot ` and run through the initial setup. This will ask for +your token and a prefix. \ No newline at end of file diff --git a/docs/install_debian.rst b/docs/install_debian.rst new file mode 100644 index 000000000..d26974109 --- /dev/null +++ b/docs/install_debian.rst @@ -0,0 +1,47 @@ +.. debian install guide + +================================ +Installing Red on Debian Stretch +================================ + +.. warning:: For safety reasons, DO NOT install Red with a root user. Instead, make a new one. + +--------------------------- +Installing pre-requirements +--------------------------- + +.. code-block:: none + + echo "deb http://httpredir.debian.org/debian stretch-backports main contrib non-free" >> /etc/apt/sources.list + apt-get update + apt-get install python3.5-dev python3-pip build-essential libssl-dev libffi-dev git ffmpeg libopus-dev unzip -y + +------------------ +Installing the bot +------------------ + +To install without audio: + +:code:`pip3 install red-discordbot` + +To install with audio: + +:code:`pip3 install red-discordbot[voice]` + +------------------------ +Setting up your instance +------------------------ + +Run :code:`redbot-setup` and follow the prompts. It will ask first for where you want to +store the data (the default is :code:`~/.local/share/Red-DiscordBot`) and will then ask +for confirmation of that selection. Next, it will ask you to choose your storage backend +(the default here is JSON). It will then ask for a name for your instance. This can be +anything as long as it does not contain spaces; however, keep in mind that this is the +name you will use to run your bot, and so it should be something you can remember. + +----------- +Running Red +----------- + +Run :code:`redbot ` and run through the initial setup. This will ask for +your token and a prefix. \ No newline at end of file diff --git a/docs/install_mac.rst b/docs/install_mac.rst new file mode 100644 index 000000000..1b695586f --- /dev/null +++ b/docs/install_mac.rst @@ -0,0 +1,39 @@ +.. mac install guide + +===================== +Installing Red on Mac +===================== + +--------------------------- +Installing pre-requirements +--------------------------- + +* Install Brew + * In Finder or Spotlight, search for and open terminal. In the window that will open, paste this: + :code:`/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"` + and press enter. +* After the installation, install the required packages by pasting the commands and pressing enter, one-by-one: + * :code:`brew install python3 --with-brewed-openssl` + * :code:`brew install git` + * :code:`brew install ffmpeg --with-ffplay` + * :code:`brew install opus` + +-------------- +Installing Red +-------------- + +To install Red, run :code:`pip3 install red-discordbot[voice]` + +---------------------- +Setting up an instance +---------------------- + +To set up an instance, run :code:`redbot-setup` and follow the steps there, providing the requested information +or accepting the defaults. Keep in mind that the instance name will be the one you use when running the bot, so +make it something you can remember + +----------- +Running Red +----------- + +Run :code:`redbot ` and go through the initial setup (it will ask for the token and a prefix). \ No newline at end of file diff --git a/docs/install_raspbian.rst b/docs/install_raspbian.rst new file mode 100644 index 000000000..61029f8cc --- /dev/null +++ b/docs/install_raspbian.rst @@ -0,0 +1,39 @@ +.. raspbian install guide + +================================== +Installing Red on Raspbian Stretch +================================== + +--------------------------- +Installing pre-requirements +--------------------------- + +.. code-block:: none + + sudo apt-get install python3.5-dev python3-pip build-essential libssl-dev libffi-dev git libav-tools libopus-dev unzip -y + +-------------- +Installing Red +-------------- + +:code:`pip3 install red-discordbot[voice]` + +---------------------- +Setting up an instance +---------------------- + +Run :code:`redbot-setup` and follow the prompts. It will ask first for where you want to +store the data (the default is :code:`~/.local/share/Red-DiscordBot`) and will then ask +for confirmation of that selection. Next, it will ask you to choose your storage backend +(the default here is JSON). It will then ask for a name for your instance. This can be +anything as long as it does not contain spaces; however, keep in mind that this is the +name you will use to run your bot, and so it should be something you can remember. + +----------- +Running Red +----------- + +Run :code:`redbot ` and run through the initial setup. This will ask for +your token and a prefix. + +.. warning:: Audio will not work on Raspberry Pi's **below** 2B. This is a CPU problem and *cannot* be fixed. \ No newline at end of file diff --git a/docs/install_ubuntu.rst b/docs/install_ubuntu.rst new file mode 100644 index 000000000..6eb1593cd --- /dev/null +++ b/docs/install_ubuntu.rst @@ -0,0 +1,45 @@ +.. ubuntu install guide + +============================== +Installing Red on Ubuntu 16.04 +============================== + +.. warning:: For safety reasons, DO NOT install Red with a root user. Instead, make a new one. + +------------------------------- +Installing the pre-requirements +------------------------------- + +.. code-block:: none + + sudo apt install python3.5-dev python3-pip build-essential libssl-dev libffi-dev git ffmpeg libopus-dev unzip -y + +------------------ +Installing the bot +------------------ + +To install without audio: + +:code:`pip3 install red-discordbot` + +To install with audio: + +:code:`pip3 install red-discordbot[voice]` + +------------------------ +Setting up your instance +------------------------ + +Run :code:`redbot-setup` and follow the prompts. It will ask first for where you want to +store the data (the default is :code:`~/.local/share/Red-DiscordBot`) and will then ask +for confirmation of that selection. Next, it will ask you to choose your storage backend +(the default here is JSON). It will then ask for a name for your instance. This can be +anything as long as it does not contain spaces; however, keep in mind that this is the +name you will use to run your bot, and so it should be something you can remember. + +----------- +Running Red +----------- + +Run :code:`redbot ` and run through the initial setup. This will ask for +your token and a prefix. \ No newline at end of file diff --git a/docs/install_windows.rst b/docs/install_windows.rst new file mode 100644 index 000000000..dc3cb2699 --- /dev/null +++ b/docs/install_windows.rst @@ -0,0 +1,37 @@ +.. windows installation docs + +========================= +Installing Red on Windows +========================= + +--------------- +Needed Software +--------------- + +* `Python `_ - Red needs at least Python 3.5 + +.. attention:: Please note that 3.6 has issues on some versions of Windows. + If you try using Red with 3.6 and experience issues, uninstall + Python 3.6 and install the latest version of Python 3.5 + +.. note:: Please make sure that the box to add Python to PATH is CHECKED, otherwise + you may run into issues when trying to run Red + +* `Git `_ + +.. attention:: Please choose the option to "Run Git from the Windows Command Prompt" in Git's setup + +-------------- +Installing Red +-------------- + +1. Open a command prompt (open Start, search for "command prompt", then click it) +2. Run the appropriate command, depending on if you want audio or not + * No audio: :code:`python -m pip install Red-DiscordBot` + * Audio: :code:`python -m pip install Red-DiscordBot[voice]` +3. Once that has completed, run :code:`redbot-setup` to set up your instance + * This will set the location where data will be stored, as well as your + storage backend and the name of the instance (which will be used for + running the bot) +4. Once done setting up the instance, run :code:`redbot ` to run Red. + It will walk through the initial setup, asking for your token and a prefix \ No newline at end of file