This template is for use to kick in fast into a Django Project.
Fork Repository
Press the fork button in top-right corner
Clone repository
$ git clone "https://github.com/username/Django-Template.git
Making Virtual Environment
python3 -m venv <name>
Activating virtual environment
Linux $ source <name>/bin/activate
Windows > source <name>/Scripts/activate
Installing required python packages
Navigate to requirements folder in the root directory
pip install -r base.txt
Install Postgresql, Create a User and Database. Also, grant all privileges of that db to User
Linux
$ sudo apt install postgresql postgresql-contrib
$ sudo -u postgres psql
Windows
http://www.postgresqltutorial.com/install-postgresql/
CREATE DATABASE yourdbname;
CREATE USER youruser WITH ENCRYPTED PASSWORD 'yourpass';
GRANT ALL PRIVILEGES ON DATABASE yourdbname TO youruser;
Create a .env file based on env.example in root directory changing the database credentials and leave other fields as it is.
Creating Django SuperUser
$ python manage.py createsuperuser
Implementing Database
$ python manage.py migrate
-
Fork the repository
-
Clone the repository with
$ git clone "https://github.com/username/Django-Template.git
- Create a branch to work upon
$ git checkout -b branchname
- Add your changes and commit them
$ git add -A
$ git commit -m"meaningful commit message"
- Push your changes to your forked copy
$ git push origin master
- Make a Pull Request