19 lines
347 B
Python
19 lines
347 B
Python
from pathlib import Path
|
|
import sys
|
|
|
|
ROOT = Path(__file__).resolve().parents[1]
|
|
sys.path.insert(0, str(ROOT))
|
|
|
|
from app.database import Base, engine # noqa: E402
|
|
from app import models # noqa: F401,E402
|
|
|
|
|
|
def main() -> None:
|
|
Base.metadata.create_all(bind=engine)
|
|
print("database tables created")
|
|
|
|
|
|
if __name__ == "__main__":
|
|
main()
|
|
|