Add honcho and just
This commit is contained in:
parent
da540a2abb
commit
56112a9655
4 changed files with 35 additions and 4 deletions
1
Procfile
Normal file
1
Procfile
Normal file
|
@ -0,0 +1 @@
|
|||
web: ./manage.py runserver
|
10
README.md
10
README.md
|
@ -2,10 +2,12 @@
|
|||
|
||||
## Installation
|
||||
|
||||
1. Create a virtual environment
|
||||
2. `pip install -r requirements.txt`
|
||||
3. Create [`.env` file](#env-file)
|
||||
4. `./manage.py runserver`
|
||||
This project handles commands using [`just`](https://github.com/casey/just).
|
||||
|
||||
1. `just install`
|
||||
2. Create [`.env` file](#env-file)
|
||||
3. `just migrate`
|
||||
4. `just start`
|
||||
|
||||
### `.env` file
|
||||
|
||||
|
|
3
dev-requirements.txt
Normal file
3
dev-requirements.txt
Normal file
|
@ -0,0 +1,3 @@
|
|||
-r requirements.txt
|
||||
|
||||
honcho==1.1.0
|
25
justfile
Normal file
25
justfile
Normal file
|
@ -0,0 +1,25 @@
|
|||
set dotenv-load
|
||||
|
||||
# Load virtualenv
|
||||
export PATH := justfile_directory() + "/env/bin:" + env_var('PATH')
|
||||
|
||||
# Dev environment
|
||||
export DEBUG := "true"
|
||||
export SECRET_KEY := "super-secret-key"
|
||||
|
||||
# Recipes
|
||||
@default:
|
||||
just --list
|
||||
|
||||
install:
|
||||
python -m venv env
|
||||
pip install -r dev-requirements.txt
|
||||
|
||||
@start:
|
||||
honcho start
|
||||
|
||||
@manage +ARGS:
|
||||
./manage.py {{ ARGS }}
|
||||
|
||||
@collectstatic:
|
||||
./manage.py collectstatic --noinput -v2
|
Loading…
Reference in a new issue