diff --git a/.idea/dictionaries/romain.xml b/.idea/dictionaries/romain.xml index 95da3c9..0299aeb 100644 --- a/.idea/dictionaries/romain.xml +++ b/.idea/dictionaries/romain.xml @@ -10,6 +10,7 @@ splt systemd tutux + tuxvenv webhooks diff --git a/Makefile b/Makefile index b888087..572fa01 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,14 @@ PYTHON = python +VENV = ~/tuxvenv + +# Init +main: + $(PYTHON) -m venv --clear $(VENV) + $(VENV)/bin/pip install -U pip setuptools +install: + $(VENV)/bin/pip install . +update: + $(VENV)/bin/pip install -U . # Blackify code reformat: diff --git a/README.md b/README.md index 3a7f3ed..90d2c47 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ It is preferable to install the bot on a dedicated user. If you don't know how t sudo pacman -Syu python python-pip python-virtualenv git ``` -Continue by [creating virtual env](#creating-a-virtual-env). +Continue to [installing Tuxbot](#installing-tuxbot). ----- @@ -33,7 +33,7 @@ sudo apt update sudo apt -y install python3 python3-dev python3-pip python3-venv git ``` -Continue by [creating virtual env](#creating-a-virtual-env). +Continue to [installing Tuxbot](#installing-tuxbot). ----- @@ -41,25 +41,19 @@ Continue by [creating virtual env](#creating-a-virtual-env). *go to hell* -## Creating a virtual env - -Make sure you have the virtualenv package installed before following the next steps. - -Create the virtual environment by executing the following command: -```shell script -python3 -m venv ~/tuxvenv -``` - -And activate it with this command: -```shell script -source ~/tuxvenv/bin/activate -``` ## Installing Tuxbot -Now, you can finish the installation by executing this single command: +To set up the virtual environnement and install the bot, simply run this two commands: + ```shell script -pip install . +make +make install +``` + +Now, switch your environment to the virtual one by run this single command: +```shell script +source ~/tuxvenv/bin/activate ``` ## Configuration