56 lines
1.3 KiB
Markdown
56 lines
1.3 KiB
Markdown
# Windows installation instructions
|
|
|
|
## Install dependencies
|
|
|
|
### Install python3
|
|
|
|
Visit [The python website](https://www.python.org/downloads/windows/) to install the latest version of python3.
|
|
|
|
Make sure to add the python binary directory to PATH. For instructions how to do this, refer to [this Stackoverflow answer](https://superuser.com/questions/143119/how-to-add-python-to-the-windows-path).
|
|
|
|
### Install virtualenv with pip
|
|
|
|
Run the following command to install `virtualenv`.
|
|
|
|
```cmd
|
|
python -m pip install virtualenv
|
|
```
|
|
|
|
Setup a virtual python environment.
|
|
|
|
```cmd
|
|
python -m virtualenv ../virtualenv.sikweb
|
|
```
|
|
|
|
## Activate virtualenv and install requirements
|
|
|
|
Activate `virtualenv` (note that this has to be active at all times).
|
|
|
|
```cmd
|
|
source ../virtualenv.sikweb/Scripts/activate
|
|
```
|
|
|
|
Run the following command to install python packages.
|
|
|
|
```cmd
|
|
pip install -r requirements.txt
|
|
```
|
|
|
|
## Run migrations
|
|
|
|
Run
|
|
|
|
```cmd
|
|
python manage.py migrate
|
|
```
|
|
|
|
## Install npm for linting javascript
|
|
|
|
Follow the instructions on [the npm website](https://www.npmjs.com/package/npm).
|
|
|
|
## Set up database
|
|
|
|
By default Django uses SQLite, which doesn't need any configuration. If you need PostgreSQL instead, refer to [their website](https://www.postgresql.org/download/windows/).
|
|
|
|
## Done
|