Project Chirp is a social networking site written using Python/Django. See demo here: https://projectchirp.herokuapp.com/
-
Create a postgres database named
chirp
with you as anowner
. -
Clone this repo(preferably use ssh clone instead of https, you won't be bothered asking for password every time you push/pull).
git clone [email protected]:skshetry/Chirp.git
-
cd
into this repo(where you cloned) and create a virtual environment(preferably, usingpython -m venv venv
onbash
/zsh
).On Windows if above didn't work,
c:\Python36\python -m venv c:\path\to\venv
.^[1] -
Activate the virtual environment(
source venv/bin/activate
).On Windows, either use
venv\Scripts\activate.bat
oncmd.exe
orvenv\Scripts\Activate.ps1
onPowerShell
(default on Windows 10). -
Install all the requirements (
pip install -r requirements/local.txt
).If this didn't work, use
python -m pip install -r requirements/local.txt
. -
Copy the file
env.example
from root of the repo in a new file.env
(dot env) in the same directory. Don't deleteenv.example
though. -
Open the file and change the
<user>
to the databaseowner
and<pass>
to the database password. -
Make migrations file and migrate.
./manage.py makemigrations
./manage.py migrate
-
Run test to ensure everything is working.
-
./manage.py test
If it doesn't, revisit all the above points. It might be that you have forgotten something along the way.
-
-
Run the development server.
./manage.py runserver
- Open the repo in your favorite text editor.
- Before you start working, create a issue and corresponding WIP(Work in Progress) branch and merge request(MR) from gitlab.
Pull that using git pull --all
and checkout to the new branch(git checkout <branchname>
).