cli/discover: remove local collections if the remote collection is deleted#868
cli/discover: remove local collections if the remote collection is deleted#868dilyanpalauzov wants to merge 1 commit intopimutils:masterfrom
Conversation
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set.
|
This pull request introduces 1 alert when merging fc49ba8 into a42906b - view on LGTM.com new alerts:
|
|
I'm not a fan of doing this by default. I've several times deleted a remote collection with the intent of pushing my local copy elsewhere. If my local copy were auto-deleted, I would have lost it permanently. I'm sure there's other scenarios where it might lead to people inadvertently losing data. I don't want people finding out about this feature the hard way 😅 I'd be okay with this with any of these changes a dedicated flag to enable / disable the behaviour. For example, something like: [pair calendars]
# ...
prune_collections = true |
|
I am utterly fine in anyway this is implemented. I provided my way of doing it. I have also diff --git a/vdirsyncer/cli/utils.py b/vdirsyncer/cli/utils.py
--- a/vdirsyncer/cli/utils.py
+++ b/vdirsyncer/cli/utils.py
@@ -404,7 +404,7 @@ def handle_collection_not_found(config, collection, e=None):
.format(f'{e}\n' if e else '',
json.dumps(collection), storage_name))
- if click.confirm('Should vdirsyncer attempt to create it?'):
+ if True or click.confirm('Should vdirsyncer attempt to create it?'):
storage_type = config['type']
cls, config = storage_class_from_config(config)
config['collection'] = collection
to create automatically Calendars, once they are created on the server. I want to have a system that periodically syncs and gets the state on the server (incl. creating new calendars and deleting old ones). For implicit calendar creation, the name |
|
Moved to #869. |
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…s deleted/created This works when the destination backend is 'filesystem'. -- add a new parameter to storage section: implicit = ["create", "delete"] pimutils#868 Changes cli/utils.py:save_status(): when data is None, remove the underlaying file.
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
…leted This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set. pimutils#868
This works when the destination backend is 'filesystem' and the source is CalDAV-calendar-home-set.