From 110e2c56f8fc1fff61fa37548f72dff8a68aaa7a Mon Sep 17 00:00:00 2001 From: mike cullerton Date: Tue, 4 Jan 2022 07:28:23 -0500 Subject: [PATCH] cli entry point for temp_migration_service. Ultimately, this will call the real service. --- crc/__init__.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/crc/__init__.py b/crc/__init__.py index ebd7e0a5..0ca1dd0c 100644 --- a/crc/__init__.py +++ b/crc/__init__.py @@ -106,6 +106,14 @@ print('TESTING = ', app.config['TESTING']) print('TEST_UID = ', app.config['TEST_UID']) print('ADMIN_UIDS = ', app.config['ADMIN_UIDS']) + +@app.cli.command() +def load_files_from_filesystem(): + """Load file data into the database.""" + from crc.services.temp_migration_service import FromFilesystemService, SYNC_FILE_ROOT + FromFilesystemService().update_file_metadata_from_filesystem(SYNC_FILE_ROOT) + + @app.cli.command() def load_example_data(): """Load example data into the database."""