Library and command-line tool to convert Norstore Archive datasets to ro-crates.
Uses Norstore Archive's basic_search API to fetch datasets in JSON format.
Can be run even without installing, by first downloading the code, then doing oine of:
- entering the
src
-directory and executingpython -m nirdarchive2rocrate
- adding
src
to $PYTHONPATH then executingpython -m nirdarchive2rocrate
If installed it can be executed with both python -m nirdarchive2rocrate
as well as nirdarchive2rocrate
.
Install with pip: pip install nirdarchive2rocrate
The actual endpoints are not included with the script. They can be put in a config-file, format:
list_endpoint = https://WHATEVER dataset_endpoint = https://WHATEVER
The config is searched for in the following files, in prioritized order:
$PWD/.nirdarchive2rocrate.toml $HOME/.nirdarchive2rocrate.toml $XDG_CONFIG_HOME/nirdarchive2rocrate.toml /usr/local/etc/nirdarchive2rocrate.toml /etc/nirdarchive2rocrate.toml
The config can be overriden by the flags --dataset_endpoint
and
--list_endpoint
.
Names of persons are encoded in base 32 to serve as an identifier, since the Norstore Archive do not use ORCID or similar identification standards.