I strongly encourage you to update, refine, and enhance this readme file!
Python v3.10.4
- Python virtual environment containing requirements from
requirements.txt
file (Django
is included there)
Documentaion by the numpy style guide looks good 👌
- API: an (incompatible) API change
- BENCH: changes to the benchmark suite
- BLD: change related to building iostore
- BUG: bug fix
- DEP: deprecate something, or remove a deprecated object
- DEV: development tool or utility
- DOC: documentation
- ENH: enhancement
- MAINT: maintenance commit (refactoring, typos, etc.)
- REV: revert an earlier commit
- STY: style fix (whitespace, PEP8)
- TST: addition or modification of tests
- REL: related to releasing iostore
example: BUG: fixed the
foo function bug from issue #1234
- open terminal (ctrl + `)
- navigate to the folder containing
manage.py
file and run:
py manage.py runserver
- open your browser and type the url:
localhost:8000
In order to create an initial db we will use fixtures
- Add users via registration in the site
- run the following command:
py .\manage.py dumpdata -o users/fixtures/users.json users
- in order to load this fixture to an empty db run the command:
py .\manage.py loaddata users
- When you start a new app with
Django
don't forget to add it toapps.py
file and add the name of the class to theINSTALLED_APP
. - It is better practice to keep most of the logic in
models.py
and notviews.py
(will result less db io)
⚠️ You can clickcopy to clipboard
button and just paste in terminal
py -m venv venv # Create a virtual environment
py -m venv venv --upgrade-deps # Update core dependencies
venv\Scripts\activate # Activate the virtual environment
deactivate # Deactivate the virtual environment
pip install -r requirements.txt --upgrade # Update packages for activated env
- add the package and desired version to the requirements.txt file
- run
pip install -r requirements.txt --upgrade
- Tell the rest of the team so they will update their env as well :)
In order to commit changes to git, you must configure name and email.
After opening a GitHub
account you will get a pseudo email, that will route to the email you logged in GitHub
with, so you don't have to put your personal email open for public.
To configure your credentials open GIT Bash
and enter the following commands:
git.config --global user.name "John wick"
git.config --global user.email "john.wick@gmail.com"
- Rerun
Django
server - Refresh page and clear cache on browser using ctrl + shift + r
- Python Django 7 Hour Course by Traversy Media
- Django Tutorials by Corey Schafer
- Python Tutorial: VENV (Windows) by Corey Schafer