Main repository for tuk lab equipment allocation system
- Python 3.6+ installed
- Django
- Text editor such as vs code or sublime text
- Git - preferrably use terminal like gitbash
- Clone the repository.
- Change directory to the location of this repository.
- Create a
.env
file using the included.env.example
as an example. - Generate a secret key for your app and paste into the SECRET_KEY section of .env file you can find generate the key from here
- Create and start your preferred Python virtual environment. Install the required libraries.
pip install -r requirements.txt
-
After installation
cd
into the project path and run the following commands:python manage.py migrate
-
A local
dbsqlite
file will be generate at the root of the project. -
Create a superuser by running the
python manage.py createsuperuser
and fill in the details. -
After run
python manage.py runserver
open the browser and runlocalhost:8000
, login with the credentials created. -
For details of how to get started with django, check out this link
-
In order to work with a virtual environment, check out this link
To run locally:
python manage.py runserver
Pull the latest master version:
git pull origin master
Create local development branch and switch to it:
git branch dev
git checkout dev
Make desired changes then commit the branch.
git add .
git commit -m "changes to dev branch"
git push origin dev