From f52bcb899d72e2f69cb90e34032b9c622322f9cd Mon Sep 17 00:00:00 2001 From: René 'Necoro' Neumann Date: Tue, 16 Aug 2016 00:04:49 +0200 Subject: Basic CLI --- archivist/model.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'archivist/model.py') diff --git a/archivist/model.py b/archivist/model.py index ce360f3..69765f3 100644 --- a/archivist/model.py +++ b/archivist/model.py @@ -50,6 +50,11 @@ class Model(Base): def get(cls, *args, **kwargs): return cls.query.get(*args, **kwargs) +def create_all(): + Model.metadata.create_all(engine) + +def drop_all(): + Model.metadata.drop_all(engine) class Prefix(Model): prefix = Column(ty.Unicode, index = True, unique = True) -- cgit v1.2.3-70-g09d2