-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
list locations #235
list locations #235
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @wgresshoff Thanks a lot for this contribution, it is really helpful. At the moment the tests are not passing I think it is because the cli.py
its lacking a last new line. Travis tests check for PEP-8 conventions, and one of those is that the python files should finish with a new line :)
I also see in the commit history that there is a "merge" commit. Could it be rebased? just so the history is clean.
In addition, the output does not show "nicely" in my (and probably also small terminals) due to the {:140}
. Could it be shortened to maybe 20 or 30?
Thanks a lot!
As discussed IRL, the "set default" functionality will be generic so the create location will also make use of it when calling with |
invenio_files_rest/cli.py
Outdated
@with_appcontext | ||
def default_location(name): | ||
"""Set default location.""" | ||
from .models import Location |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Imports should be on the beginning on the file.
Just added fix for #232 |
Slight refactoring to fixt tests. (@wgresshoff sorry I had to take out the pretty print it is a nice addition but it requires a bigger refactor along invenio). Warning it is not backwards compatible:
|
Continued in #236 |
In order to set a default location I need to know which are existing.
Closes #234
Closes #232