Page MenuHomeSoftware Heritage

deposit.cli: Align cli like other modules + update documentation
ClosedPublic

Authored by ardumont on Mar 12 2019, 9:52 PM.

Details

Summary
  • swh.deposit.cli: Migrate client command as main cli subcommand
  • Allow auto-completion to work (Add eval "$(_SWH_DEPOSIT_COMPLETE=$autocomplete_cmd swh-deposit)" in $VIRTUAL_ENV/bin/postactivate)
  • Allow to use --config-file to pass extra config file
  • Update documentation accordingly

Related T1580

Test Plan

tox

Diff Detail

Repository
rDDEP Push deposit
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 4644
Build 6168: tox-on-jenkinsJenkins
Build 6167: arc lint + arc unit

Event Timeline

ardumont added inline comments.
swh/deposit/cli.py
449

In real life, what do our users need to do to have completion?

Do they need to add something in the .*shrc configuration (like the eval instruction we add to our virtual env postactivate script)?

I think the subcommand should be named "deposit" instead of "client", because what matters is what it does, not what it is.

I think the subcommand should be named "deposit" instead of "client", because what matters is what it does, not what it is.

that makes sense, thanks.

I kept client solely because the previous cli (i migrated that code from) was dubbed 'swh.deposit.client.cli'...

swh/deposit/cli.py
449

yes, that's what i was referring to by like the eval instruction we add to our virtual env postactivate script ;)

So i'm guessing that you confirm that they need to add something similar in their *shrc routine.

This revision is now accepted and ready to land.Mar 14 2019, 4:32 PM
  • deposit.cli: Rename client subcommand to deposit
This revision was automatically updated to reflect the committed changes.