chore: Initialize project

This commit is contained in:
fit2cloud-chenyw
2025-04-21 17:51:16 +08:00
parent 9f76e5f88a
commit 12911d0afe
96 changed files with 3676 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
#!/bin/sh -e
set -x
ruff check app scripts --fix
ruff format app scripts
+8
View File
@@ -0,0 +1,8 @@
#!/usr/bin/env bash
set -e
set -x
mypy app
ruff check app
ruff format app --check
+13
View File
@@ -0,0 +1,13 @@
#! /usr/bin/env bash
set -e
set -x
# Let the DB start
python app/backend_pre_start.py
# Run migrations
alembic upgrade head
# Create initial data in DB
python app/initial_data.py
+8
View File
@@ -0,0 +1,8 @@
#!/usr/bin/env bash
set -e
set -x
coverage run --source=app -m pytest
coverage report --show-missing
coverage html --title "${@-coverage}"
+7
View File
@@ -0,0 +1,7 @@
#! /usr/bin/env bash
set -e
set -x
python app/tests_pre_start.py
bash scripts/test.sh "$@"