* Acquire account settings via address book account
* Extract the code to find an address books main account to the account repository
* Use collection id as reference in address book account
* Remove obsolete baos
* Find main account directly from collection in SyncManager
* Require main account to get account settings
* Stop deleting address book accounts without a main account, since they may exist on their own now
* Require content provider and introduce static deleteByCollection method
* Update KDoc
* Show all address book accounts separately
* Drop mainAccount method
* [DI] Use AssistedInject for LocalAddressBook
* Renaming, remove "main account" concept
* Fix debug info
* AccountsCleanupWorker: Rename main account to account
* Further remove main accounts
* Reduce redundancy
* AccountSettings: check account type
* AccountSettingsMigrations: drop v5 -> v6 migration (not tested anyway)
* AccountRepository: directly delete accounts
* Remove obsolete workerAccount
* Get all address books, even if not sync enabled
* Delete orphan address book accounts
* Rename two more occurrences of main account concept
* AccountSettings: allow test accounts
* Syncer: rename methods for clarity, add KDoc
* Drop empty test class
* Make code more readable and add comment
---------
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
* Added `BUILD_DATE` environment variable
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
* Excluded `generated`
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
* Removed argument
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
* Using build time from git
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
* Removed unused import
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
* Got rid of build date
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
* Got rid of build date
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
---------
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
* Disabled `CoroutineCreationDuringComposition` in lint
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
* Moved disable
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
---------
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
* Update ical4android
* Use standard content provider in TaskSyncer
* Check version instead of acquiring TaskProvider
* Add sync result error
---------
Co-authored-by: Arnau Mora <arnyminerz@proton.me>
* Fix overlapping method name and use interface everywhere
* Fix overlapping property name
* Update logger usage
---------
Co-authored-by: Arnau Mora Gras <arnyminerz@proton.me>
* Passing `collection` directly
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
* Fixed imports
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
* Fix tests
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
* Log sync time using repository; no need for account/service check anymore
* SyncManagerTest: don't write SyncStats to DB
---------
Signed-off-by: Arnau Mora Gras <arnyminerz@proton.me>
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
* Use address book contacts content provider provided by syncer
* Close any acquired content provider after sync
* Acquire/Check task provider provider as preparation step
* Provide sync arguments at syncer creation
* Acquire ContentProviderClient in syncer implementations
* Generalize sync algorithm in Syncer
* Use contacts authority for address books
* Generalize sync algorithm in CalendarSyncer
* Generalize sync algorithm in SyncerTest
* Generalize sync algorithm in TaskSyncer
* Rename preparation method and add an after sync method
* Generalize sync algorithm in JtxSyncer
* Generalize sync algorithm in AddressBookSyncer
* Use repositories instead of DAOs
* Replace deprecated log statements
* Use generic type for collection types
* Infer authorities when possible and pass only task authorities along
* No need to close TaskProvider explicitly
* Use colors only where needed
* Use provider with auto closable
* Get sync collections in syncer implementations
* Delete syncer test
* Pass provider through methods instead of using lateinit property
* Reorder constructor arguments
* Remove trailing commas
* Remove obsolete undocumented conditional
* Reorder methods
* Reorder methods
* Abort sync when preparations fail
* Drop obsolete permission check
* Use generics for url and delete
* Use generic for update
* Use generic for syncCollection
* Rename create to createCollection for consistency
* Revert "Rename create to createCollection for consistency"
This reverts commit 0fee4fe7fc.
* Revert "Use generic for syncCollection"
This reverts commit ae129fd17e.
* Revert "Use generic for update"
This reverts commit 42dd665851.
* Revert "Use generics for url and delete"
This reverts commit 7ae1425039.
* Move delete() to LocalCollection
* Move url to LocalCollection
* Fix local test collection
* Minor changes
* Minor changes
- make sync private
- use to autoclose provider
* Query for sync collections once only
* Add KDoc and update comments
* Make property a local variable
* Update KDoc
* Add back ose conditional
* Remove blank line at beginning of method
---------
Co-authored-by: Ricki Hirner <hirner@bitfire.at>
* Use test account type (without sync adapters as side effects) for instrumented tests
* Provide standardized way to get test account; re-enable LocalAddressBookTest