From 3f9d7fe6e040500e4f3280a5023269aef72ce66b Mon Sep 17 00:00:00 2001 From: Christopher Byrd Date: Fri, 7 Feb 2025 10:45:47 -0800 Subject: [PATCH] adds arches_component_lab as a dependency #209 --- arches_lingo/settings.py | 1 + import_lingo_example_data.py | 10 ++++++++++ 2 files changed, 11 insertions(+) create mode 100644 import_lingo_example_data.py diff --git a/arches_lingo/settings.py b/arches_lingo/settings.py index 7d78dbd7..f32be42c 100644 --- a/arches_lingo/settings.py +++ b/arches_lingo/settings.py @@ -239,6 +239,7 @@ def get_optional_env_variable(var_name, default=None) -> str: "django.contrib.gis", "django_hosts", "arches_controlled_lists", + "arches_component_lab", "arches_vue_utils", "arches", "arches.app.models", diff --git a/import_lingo_example_data.py b/import_lingo_example_data.py new file mode 100644 index 00000000..7261a4ce --- /dev/null +++ b/import_lingo_example_data.py @@ -0,0 +1,10 @@ +import os +import subprocess + +data_directory = './tests/fixtures/data' + +for filename in os.listdir(data_directory): + file_path = os.path.join(data_directory, filename) + if os.path.isfile(file_path): + command = f'python manage.py packages -o import_business_data -s {file_path} -ow overwrite' + subprocess.run(command, shell=True) \ No newline at end of file