Skip to content

Commit

Permalink
docs: fix development setup instructions in README.md
Browse files Browse the repository at this point in the history
setup-db.py requires a third argument as it also allows to update a
database so 0 needs to be explicitly given for full initialization.
(TODO: maybe default to 0 if not provided?)

It also requires the database uri in order to properly initalize the
database. The secret key is not necessary for the operation but needed
for the application initalization.
  • Loading branch information
div72 committed Oct 25, 2022
1 parent 0371d1c commit 5f285b0
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@ Open source form application made with pure HTML/CSS/JS. Needs minimal client-si
## Setup

```sh
export SQLALCHEMY_DATABASE_URI="sqlite:///test.db"
export SECRET_KEY="fiesta"
python3 -m venv venv && source venv/bin/activate
pip install -r requirements.txt
python3 setup-db.py
python3 setup-db.py 0

# Run with:
source venv/bin/activate
FLASK_APP=formie FLASK_ENV=development SQLALCHEMY_DATABASE_URI="sqlite:///test.db" SECRET_KEY="fiesta" flask run
FLASK_APP=formie FLASK_ENV=development flask run
```

0 comments on commit 5f285b0

Please sign in to comment.