Skip to content

eLTER-RI/dar-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 

Repository files navigation

DAR CLI

Command line interface tool for creating draft records and uploading files in Invenio Dar component.

Features

  • Create record drafts
    • Single draft creation
    • Batch draft creation - not implemented yet
  • Edit draft metadata - not implemented yet
  • Upload files to drafts (maximum 100GB per file)
    • Single file upload
    • Batch file upload
  • Delete drafts

Requirements

  • Python 3.10 or higher
  • Generated user token in the Dar

Linux Installation and run

pip install mu-invenio-cli
mu-invenio-cli

Alternate Installation (Windows)

py -m pip install --user pipx
py -m pipx ensurepath (reopen terminal)
pipx install mu-invenio-cli
mu-invenio-cli

Updating -- to keep up with latest features

pip install --upgrade mu-invenio-cli
# or
pipx upgrade mu-invenio-cli

Troubleshooting

If you encounter an error related to tkinter, you might need to install additional dependencies based on your operating system.

Linux users might need to install tkinter dependencies:

sudo apt-get install python3-tk

Windows users might need to install tcl/tk dependencies - if Python was installed via chocolatey:

choco install tcl
choco install tk

MacOS users might need to install tcl/tk dependencies - if Python was installed via brew:

brew install tcl-tk

Required configuration

Config file is created during the first run and can be edited via the cli tool.

Variables:

  • BASE_API_URL = URL of the Invenio API (for our dar repository: https://dar.elter-ri.eu/api/)
  • API_TOKEN = User token generated in the Dar
  • MODEL = Model of the record (e.g. datasets, external-datasets)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published