mirror of
https://github.com/Llloooggg/Dyxless.git
synced 2026-03-06 10:46:24 +03:00
Создание базы данных перенесено в основной код
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import os
|
||||
import json
|
||||
|
||||
from flask import Flask
|
||||
@@ -55,3 +56,6 @@ app.register_blueprint(main_blueprint)
|
||||
from .mails import mails as mails_blueprint
|
||||
|
||||
app.register_blueprint(mails_blueprint)
|
||||
|
||||
if not os.path.exists(app.config["SQLALCHEMY_DATABASE_URI"]):
|
||||
db.create_all(app=app)
|
||||
|
||||
@@ -1,10 +1,6 @@
|
||||
|
||||
@echo off
|
||||
|
||||
if not exist "db.sqlite" (
|
||||
python init_db.py
|
||||
)
|
||||
|
||||
set FLASK_APP=dyxless
|
||||
set FLASK_ENV=development
|
||||
|
||||
|
||||
Reference in New Issue
Block a user