Skip to content

Commit

Permalink
Export: Print collections and components if debugging is enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
Unrud committed Jul 24, 2017
1 parent 4a09645 commit d069be5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions radicale/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ def export_storage(config, path, debug=False):
exit(1)
while remaining_collections:
collection = remaining_collections.pop(0)
if debug:
print("DEBUG: Exporting collection %r" %
("/" + collection.path))
try:
try:
filesystem_path = pathutils.path_to_filesystem(
Expand Down Expand Up @@ -94,6 +97,9 @@ def export_storage(config, path, debug=False):
with open(props_filename, "w") as f:
json.dump(props, f)
for component in collection.components:
if debug:
print("DEBUG: Exporting component %r of collection %r"
% (component.name, "/" + collection.path))
try:
if not pathutils.is_safe_filesystem_path_component(
component.name):
Expand Down

0 comments on commit d069be5

Please sign in to comment.