From d9dfe06270a3e5ee81d48b682a33497336470328 Mon Sep 17 00:00:00 2001 From: Giacomo Lanza <37865804+Zack-83@users.noreply.github.com> Date: Thu, 25 Apr 2024 08:15:17 +0200 Subject: [PATCH 1/6] Improve README.md --- rdmorganiser/README.md | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/rdmorganiser/README.md b/rdmorganiser/README.md index 43e26f40..eff7883a 100644 --- a/rdmorganiser/README.md +++ b/rdmorganiser/README.md @@ -1,18 +1,24 @@ RDMO catalog ============ -This repository contains the content for [RDMO](https://github.com/rdmorganiser/rdmo) prepared by the [RDMO-Project](https://rdmorganiser.github.io). +This folder contains the content for [RDMO](https://github.com/rdmorganiser/rdmo) curated by the [RDMO-Project](https://rdmorganiser.github.io). -To install the catalog into a freshly installed instance of RDMO, use +Install content +--------------- + +The RDMO content objects (catalogs, attributes, options, conditions, views, tasks) depend on each other, as shown in the [documentation](https://rdmo.readthedocs.io/en/latest/management/data-model.html). + +In particular, the installation of question catalogues requires the newest version of attributes, optionsets and conditions. + +Therefore we suggest this sequence to install content in a RDMO instance: ``` ./manage.py import /path/to/domain/rdmo.xml -./manage.py import /path/to/conditions/rdmo.xml # yes, again ./manage.py import /path/to/options/rdmo.xml -./manage.py import /path/to/conditions/rdmo.xml # yes, again -./manage.py import /path/to/questions/rdmo.xml -./manage.py import /path/to/tasks/rdmo.xml -./manage.py import /path/to/views/rdmo.xml +./manage.py import /path/to/conditions/rdmo.xml +./manage.py import /path/to/questions/.xml +./manage.py import /path/to/tasks/.xml +./manage.py import /path/to/views/.xml ``` Use the same order when importing over the RDMO web interface. From e96ff5c828572e353ca32008be5512fc4667a4ef Mon Sep 17 00:00:00 2001 From: Giacomo Lanza <37865804+Zack-83@users.noreply.github.com> Date: Thu, 25 Apr 2024 08:17:28 +0200 Subject: [PATCH 2/6] Update rdmorganiser/README.md --- rdmorganiser/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rdmorganiser/README.md b/rdmorganiser/README.md index eff7883a..b8b5bc95 100644 --- a/rdmorganiser/README.md +++ b/rdmorganiser/README.md @@ -1,7 +1,7 @@ RDMO catalog ============ -This folder contains the content for [RDMO](https://github.com/rdmorganiser/rdmo) curated by the [RDMO-Project](https://rdmorganiser.github.io). +This folder contains the content for [RDMO](https://github.com/rdmorganiser/rdmo) curated by the [RDMO Consortium](https://rdmorganiser.github.io/Community/). Install content --------------- From ae7a17ce9161544cb70fac64267d334c750f1a4b Mon Sep 17 00:00:00 2001 From: Giacomo Lanza <37865804+Zack-83@users.noreply.github.com> Date: Mon, 29 Apr 2024 11:14:16 +0200 Subject: [PATCH 3/6] Update README.md --- rdmorganiser/README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/rdmorganiser/README.md b/rdmorganiser/README.md index b8b5bc95..26a4faff 100644 --- a/rdmorganiser/README.md +++ b/rdmorganiser/README.md @@ -14,8 +14,9 @@ Therefore we suggest this sequence to install content in a RDMO instance: ``` ./manage.py import /path/to/domain/rdmo.xml -./manage.py import /path/to/options/rdmo.xml ./manage.py import /path/to/conditions/rdmo.xml +./manage.py import /path/to/options/rdmo.xml +./manage.py import /path/to/conditions/rdmo.xml # yes, again ./manage.py import /path/to/questions/.xml ./manage.py import /path/to/tasks/.xml ./manage.py import /path/to/views/.xml From 52c8d6a9f92996f9ac310644c0d7aa4e781f1af0 Mon Sep 17 00:00:00 2001 From: Giacomo Lanza <37865804+Zack-83@users.noreply.github.com> Date: Mon, 29 Apr 2024 11:14:50 +0200 Subject: [PATCH 4/6] Update rdmorganiser/README.md --- rdmorganiser/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rdmorganiser/README.md b/rdmorganiser/README.md index 26a4faff..7a34faa9 100644 --- a/rdmorganiser/README.md +++ b/rdmorganiser/README.md @@ -16,7 +16,7 @@ Therefore we suggest this sequence to install content in a RDMO instance: ./manage.py import /path/to/domain/rdmo.xml ./manage.py import /path/to/conditions/rdmo.xml ./manage.py import /path/to/options/rdmo.xml -./manage.py import /path/to/conditions/rdmo.xml # yes, again +./manage.py import /path/to/conditions/rdmo.xml # yes, again ./manage.py import /path/to/questions/.xml ./manage.py import /path/to/tasks/.xml ./manage.py import /path/to/views/.xml From df399f705d044ff47b13315dc82428917c1c7cc8 Mon Sep 17 00:00:00 2001 From: Zack-83 Date: Mon, 29 Apr 2024 13:34:36 +0200 Subject: [PATCH 5/6] integrate inner README into outer README --- README.md | 52 ++++++++++++++++++++++++++++++++++++++---- rdmorganiser/README.md | 36 ----------------------------- 2 files changed, 48 insertions(+), 40 deletions(-) delete mode 100644 rdmorganiser/README.md diff --git a/README.md b/README.md index d2395f1a..cb85c1aa 100644 --- a/README.md +++ b/README.md @@ -2,13 +2,57 @@ ![Tests](https://github.com/rdmorganiser/rdmo-catalog/actions/workflows/tests.yaml/badge.svg) -The repository holds XML files that can be imported into RDMO. They contain different kinds of information like for example the domain model, question catalogs or optionsets. +This repository contains all content objects (catalogs, attributes, options, conditions, views, tasks) to be used with the DMP software [RDMO](https://github.com/rdmorganiser/rdmo) -The files that are officially provided by the RDMO project are in the `rdmorganiser` folder. We recommend to import these files to be able to make use of the official domain model, options, tasks and conditions. *Note that parts of these data are required to import user content because RDMO user's question catalogs may refer to parts of the official data*. +The content officially curated by the [RDMO Consortium](https://rdmorganiser.github.io/Community/) is in the [`rdmorganiser`](./rdmorganiser) folder. We recommend to import these files to be able to make use of the official domain model, options, tasks and conditions. *Note that parts of these data are required to import user content because RDMO user's question catalogs may refer to parts of the official data*. -Content shared by RDMO Users can be found under `shared`. There may be multiple files in a folder like for example conditions, options and questions. Files in the same folder belong together. All of them should be imported. Please pay attention to the order in which you import files. Question catalogs referring to other content should be imported at last. +Content shared by RDMO Users can be found under [`shared`](./shared). There may be multiple files in a folder like for example conditions, options and questions. Files in the same folder belong together: all of them should be imported. -Different scripts are located in `tools`. These are interesting for people maintaining this repo. +Please pay attention to the order in which you import files. Question catalogs referring to other content should be imported at last. See the following section for details. + +Different scripts are located in [`tools`](./tools). These are interesting for people maintaining this repo. + +# How to install content + +The RDMO content objects (catalogs, attributes, options, conditions, views, tasks) depend on each other, as shown in the [documentation](https://rdmo.readthedocs.io/en/latest/management/data-model.html). + +In particular, the installation of question catalogues requires the newest version of attributes, optionsets and conditions. + +Therefore we suggest this sequence to install content in a RDMO instance: + +## Via the RDMO web interface + +Management --> Attributes --> Import .xml +Management --> Conditions --> Import .xml +Management --> Option sets --> Import .xml +Management --> Conditions --> Import .xml # yes, again +Management --> Questions --> Import .xml +Management --> Tasks --> Import .xml +Management --> Views --> Import .xml + +REMARK: If the chosen catalog is available as a **full XML**, it already includes the necessary attributes, conditions and options. + +## Via a Python script + +```python +./manage.py import //rdmo.xml +./manage.py import //rdmo.xml +./manage.py import //rdmo.xml +./manage.py import //rdmo.xml # yes, again +./manage.py import //.xml +./manage.py import //.xml +./manage.py import //.xml +``` + +Use the same order when importing over the RDMO web interface. + +Please note that the master branch will only work with the latest version of RDMO. If you need the xml files for an older version, please browse the releases or contact us. + +To indent the XML files use: + +```bash +for f in *.xml; do xmllint --format $f > /tmp/$f; mv /tmp/$f $f; done +``` ## Issues diff --git a/rdmorganiser/README.md b/rdmorganiser/README.md deleted file mode 100644 index 7a34faa9..00000000 --- a/rdmorganiser/README.md +++ /dev/null @@ -1,36 +0,0 @@ -RDMO catalog -============ - -This folder contains the content for [RDMO](https://github.com/rdmorganiser/rdmo) curated by the [RDMO Consortium](https://rdmorganiser.github.io/Community/). - -Install content ---------------- - -The RDMO content objects (catalogs, attributes, options, conditions, views, tasks) depend on each other, as shown in the [documentation](https://rdmo.readthedocs.io/en/latest/management/data-model.html). - -In particular, the installation of question catalogues requires the newest version of attributes, optionsets and conditions. - -Therefore we suggest this sequence to install content in a RDMO instance: - -``` -./manage.py import /path/to/domain/rdmo.xml -./manage.py import /path/to/conditions/rdmo.xml -./manage.py import /path/to/options/rdmo.xml -./manage.py import /path/to/conditions/rdmo.xml # yes, again -./manage.py import /path/to/questions/.xml -./manage.py import /path/to/tasks/.xml -./manage.py import /path/to/views/.xml -``` - -Use the same order when importing over the RDMO web interface. - -Please note that the master branch will only work with the latest version of RDMO. If you need the xml files for an older version, please browse the releases or contact us. - -Reindent --------- - -To indent the XML files use: - -```bash -for f in *.xml; do xmllint --format $f > /tmp/$f; mv /tmp/$f $f; done -``` From be087fc4f003826d416efa656672097aae3e7042 Mon Sep 17 00:00:00 2001 From: Giacomo Lanza <37865804+Zack-83@users.noreply.github.com> Date: Mon, 29 Apr 2024 16:32:44 +0200 Subject: [PATCH 6/6] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index cb85c1aa..3f866406 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ Therefore we suggest this sequence to install content in a RDMO instance: Management --> Attributes --> Import .xml Management --> Conditions --> Import .xml -Management --> Option sets --> Import .xml +Management --> Option sets --> Import .xml Management --> Conditions --> Import .xml # yes, again Management --> Questions --> Import .xml Management --> Tasks --> Import .xml