23 lines
No EOL
615 B
Python
23 lines
No EOL
615 B
Python
import aiosqlite
|
|
|
|
async def connect(path = './data/your_database.db') -> aiosqlite.Connection:
|
|
return await aiosqlite.connect(path)
|
|
|
|
async def create(conn: aiosqlite.Connection):
|
|
import products.db as product_db
|
|
await product_db.create(conn)
|
|
|
|
import ingredients.db as ingredient_db
|
|
await ingredient_db.create(conn)
|
|
|
|
import recipes.db as recipe_db
|
|
await recipe_db.create(conn)
|
|
|
|
import persons.db as person_db
|
|
await person_db.create(conn)
|
|
|
|
import meals.db as meals_db
|
|
await meals_db.create(conn)
|
|
|
|
import shopping.db as shopping_db
|
|
await shopping_db.create(conn) |