A frontend repository for https://burplist.com built using PyWebIO.
The site serves as a search engine for craft beers in Singapore, providing craft beer lovers pricing information for their favorite beer.
I have documented some of my thought process and engineering decisions while creating Burplist here. Enjoy!
- Python 3.9+
- poetry
- PostgreSQL
-
Make sure you have a running instance of the latest PostgreSQL in your local machine
-
Example to spin up a PostgreSQL Docker instance locally
docker run -d --name dpostgres -p 5432:5432 -e POSTGRES_HOST_AUTH_METHOD=trust postgres:latest
-
Create a new database name as
burplist
-
Ensure that
pg_trgm
is installed as your PostgreSQL extensionCREATE EXTENSION pg_trgm;
poetry install
# Installing dependencies only
poetry install --no-root
# Updating dependencies to their latest versions
poetry update
Before you begin your development work, make sure you have installed pre-commit hooks.
Some example useful invocations:
pre-commit install
: Default invocation. Installs the pre-commit script alongside any existing git hooks.pre-commit install --install-hooks --overwrite
: Idempotently replaces existing git hook scripts with pre-commit, and also installs hook environments.
Check out /src/settings.py
and configure them accordingly.
poetry run python3 app.py --debug=True --port=8080
# At `http://localhost:8080/`
You'll need to setup your Postgres locally based on the instructions here. And then run:
docker start dpostgres
# build docker image.
make build
# run local development server in docker.
make run
Your server should be live at to http://localhost:8080.
This project is currently hosted on Heroku.
heroku git:remote -a burplist-frontend-staging --staging
# Print logs for staging
heroku logs --tail --remote staging
# Print logs for production
heroku logs --tail --remote heroku
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
- Fork this
- Create your feature branch (
git checkout -b feature/bar
) - Please make sure you have installed the
pre-commit
hook and make sure it passes all the lint and format check - Commit your changes (
git commit -am 'feat: add some bar'
, make sure that your commits are semantic) - Push to the branch (
git push origin feature/bar
) - Create a new Pull Request