Torsten Grote
e6e6154b7d
Add launcher icon for debug builds
2024-08-15 09:56:19 -03:00
Torsten Grote
66836c875c
Fixes for MD3 that got merged in the meantime
2024-07-31 15:09:44 -03:00
Torsten Grote
118b2c0be0
Integrate files selection into real Seedvault app
2024-07-31 15:09:43 -03:00
Torsten Grote
dbb40a4a5b
Only attempt to do a manual app backup, if it is actually enabled
2024-07-31 15:09:43 -03:00
Torsten Grote
7d6ab6f8e0
Make demo restore with file selection functional
...
This injects FileSelectionManager as a singleton, so we can use its selection to recreate a snapshot, even in a service.
Also includes some UI improvements.
2024-07-31 15:09:43 -03:00
Torsten Grote
5012099419
Add UI prototype for selecting file to storage demo app
2024-07-31 15:09:43 -03:00
t-m-w
a00ee0fa4f
Fix AOSP build
2024-07-31 11:02:33 -04:00
Aayush Gupta
2f96393a89
Apply dynamic colors to all acitvites
...
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-07-26 15:53:10 +07:00
Aayush Gupta
3f7022ecb7
fragment_restore_app_selection: Set background color to squashed layout
...
CollapsingToolbarLayout doesn't seems to be respecting background color for some reason
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-07-11 16:57:06 +07:00
Aayush Gupta
70413f1425
drawable: Tint colors directly instead of relying on system theme
...
Material theme seems to be not respecting the tint color in the XML.
Override the colors manually to get the job done.
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-07-11 16:39:52 +07:00
Torsten Grote
0dcab41fd1
Use MD3 switches in settings
2024-07-11 15:59:03 +07:00
Aayush Gupta
98c6ebab8d
SchedulingFragment: Implement Material3 based ListPreference
...
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-07-11 15:59:03 +07:00
Aayush Gupta
d15fe36638
RecoveryCodeInputFragment: Switch to MaterialAutoCompleteTextView
...
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-07-11 15:59:02 +07:00
Aayush Gupta
cdcb862d9d
Migrate to MaterialAlertDialog everywhere
...
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-07-11 15:59:02 +07:00
Aayush Gupta
033498aa17
themes: Switch to Material3 theme
...
* Merge accent and primary color for simpler color management
* Apply background color on status and navigation bar
* Drop non-required colors
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-07-11 15:59:02 +07:00
Aayush Gupta
412ed9ee16
themes: Switch to single theme for all activities
...
Default to NoActionBar theme and use toolbar where required
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-07-11 15:59:02 +07:00
Torsten Grote
b07bb6bc48
Merge pull request #692 from grote/679-consider-other-transports
...
Better scheduling co-existence with other transport
2024-07-08 15:32:24 -03:00
Torsten Grote
490c7882e4
Add missing docs for sendBackupData()
2024-06-27 17:20:06 -03:00
Torsten Grote
7afd496db9
Catch the underlying exception when WebDAV writing fails due to closed pipe
2024-06-27 17:20:05 -03:00
Torsten Grote
823eb4ffab
Improve logging relevant for WebDAV streams
2024-06-27 16:34:37 -03:00
Torsten Grote
a1f6be0447
Remove dav4jvm InputStream hack as not needed with latest version
2024-06-24 13:53:08 -03:00
Torsten Grote
6e84d727c2
Update dav4jvm to b8be778
...
as recommended by upstream: https://github.com/bitfireAT/dav4jvm/discussions/36#discussioncomment-9862613
2024-06-24 13:48:40 -03:00
Torsten Grote
520074521e
Update okhttp to 4.12.0
2024-06-24 13:09:49 -03:00
Torsten Grote
484767bf16
Disable framework scheduling when scheduling backup, because another transport may have re-enabled it
2024-06-19 09:29:22 -03:00
Torsten Grote
878492088d
Don't disable framework scheduling when not current transport
2024-06-19 09:29:22 -03:00
Torsten Grote
97093ca0b2
Don't restore the storage provider app
...
otherwise it gets killed during data restore which kills our restore process
2024-06-19 09:24:01 -03:00
Torsten Grote
22ca2550c2
Merge pull request #670 from grote/309-restore-choose-apps
...
Allow choosing which apps will get restored
2024-06-19 09:21:59 -03:00
Torsten Grote
f15018253c
Prevent NoClassDefFound error when a WebDAV server returns GetLastModified
...
which happens in the case of dufs (see last commit)
2024-06-14 09:17:52 -03:00
Torsten Grote
4ac02018fa
Fix uncaught throwable with dufs WebDAV server
...
The underlying issue will affect other functionality though: https://github.com/sigoden/dufs/issues/400
2024-06-14 09:17:52 -03:00
Torsten Grote
56e26083fc
Fix PROPFIND fallback for lighttpd as well
2024-06-14 09:17:51 -03:00
Torsten Grote
1dd898b068
Add fallback when WebDAV PROPFIND with depth=2 isn't supported
2024-06-14 09:17:51 -03:00
Torsten Grote
c522c460fd
Add trailing slash to WebDAV collection requests
2024-06-14 09:17:50 -03:00
Torsten Grote
c483332b15
Try to fix issue where our transport doesn't get registered in emulator
2024-06-12 09:57:24 -03:00
Steve Soltys
08727651af
Skip magic package manager in assertions
...
We still don't know why, but after latest test fixes, the @pm@ package didn't have the the @meta@ key in the backup, but it did in restore.
2024-06-07 09:35:15 -03:00
Torsten Grote
e76ab1ca43
Increase WebDAV timeouts and declare body one-shot
...
As most output streams come from the system, we can't re-send them. So when okhttp wants to retry it tries to write to closed streams which will fail. We declare our outputstream writing as one-shot for this reason.
2024-06-05 12:40:42 -03:00
Torsten Grote
0e224b1238
Filter out @end@ helper package
...
it doesn't really exist and should probably not even be in the backup metadata. It messes up progress reporting, if we keep it in.
2024-05-31 17:11:34 -03:00
Torsten Grote
fa19261d8e
Improve app data restore process
...
Apps are now restored alphabetically to be consistent with the other lists. Some irrelevant apps are hidden. Under the hood, we now use an AsyncListDiffer like in the other lists.
2024-05-31 17:06:14 -03:00
Torsten Grote
b3f93adf77
Factor out code into new
...
AppDataRestoreManager
which was in RestoreViewModel before.
Now all three steps of app restore have their own dedicated manager class making the ViewModel more readable.
2024-05-31 15:07:35 -03:00
Torsten Grote
66f3852edf
Delete cached icons after restore is done
2024-05-31 13:35:55 -03:00
Torsten Grote
ebf68cfe73
Don't try to install system apps without APK
...
during restore process. These can usually not be manually installed anyway and just clutter the list making it harder for the user to find their important apps and potential failures there.
2024-05-31 12:16:01 -03:00
Torsten Grote
f408381d18
Fix backup/restore instrumentation tests
2024-05-31 11:50:59 -03:00
Torsten Grote
88619b94c1
Fix red error color
...
Resources$NotFoundException: Resource ID #0x7f060258 type #0x2 is not valid
2024-05-31 11:50:59 -03:00
Torsten Grote
f68fa0f3fc
Fix AOSP build
2024-05-31 11:50:59 -03:00
Torsten Grote
4b1c76d585
don't record excluded apps in backup
2024-05-31 11:50:59 -03:00
Torsten Grote
e54d96d548
Re-factor and improve ApkRestore
2024-05-31 11:50:59 -03:00
Torsten Grote
05c39e98fa
Add tests for AppSelectionManager
2024-05-31 11:50:58 -03:00
Torsten Grote
6143ec04ed
Upgrade Roboeletric and bump minSdk to 34
2024-05-31 11:50:58 -03:00
Torsten Grote
9cc72bfa38
Show size for (all combined) system apps when restoring
2024-05-31 11:50:58 -03:00
Torsten Grote
f5fb9ffffa
Factor out app restore selection code into new AppSelectionManager
2024-05-31 11:50:58 -03:00
Torsten Grote
332387fd58
Encrypt zip file with icons
...
While we still don't guarantee that an attacker with access to the storage can't find out which apps we use (APKs are still unencrypted after all), we go into this direction.
Also, this should make it impossible for an attacker that can modify files to replace or otherwise mess with the icons.
2024-05-31 11:10:12 -03:00
Torsten Grote
eecfcdb285
Improve icon display when selecting apps for restore
2024-05-31 11:10:12 -03:00
Torsten Grote
787b9346a8
Add meta item for restoring all (internal) system apps
...
This way we don't need to show the long complicated list, but provide an all or nothing option at least.
2024-05-31 11:10:11 -03:00
Torsten Grote
573e48f393
Sort app selection like backup status and show sections
...
system data comes first and then apps
2024-05-31 11:10:11 -03:00
Torsten Grote
af1b3de9cb
Fix icon colors (again!)
...
see 5662409ef5
2024-05-31 11:10:11 -03:00
Torsten Grote
a447895079
Cleaned up backup status list by separating system data and apps
2024-05-31 11:10:11 -03:00
Torsten Grote
1ac613f588
Also store icons of launchable system apps
2024-05-31 11:10:11 -03:00
Torsten Grote
a0a3e871e0
Show actual app name in app selection for restore
2024-05-31 11:10:11 -03:00
Torsten Grote
1667d44967
Sort apps that failed to install by name
2024-05-31 11:10:10 -03:00
Torsten Grote
56d8d64261
Store app name and whether it is a launchable system app in metadata
...
this is helpful for restore, so the user can see app names when deciding which apps to restore
2024-05-31 11:10:10 -03:00
Torsten Grote
5a2f1187a8
Store app icons in separate file
...
so they can be shown when selecting apps for restore which is before we have downloaded the APK files to extract icons from
2024-05-31 11:10:10 -03:00
Torsten Grote
905340770c
Allow user to choose which apps should get restored
2024-05-31 11:10:10 -03:00
Torsten Grote
4803288629
Show other (launchable) system apps in backup status
2024-05-31 11:10:10 -03:00
Torsten Grote
16813395c7
Change app excludes from switches to checkboxes
...
apparently this is closer to the material design specs:
https://m2.material.io/components/checkboxes#usage
2024-05-31 11:10:10 -03:00
Aayush Gupta
6953f154b3
gradle: Migrate to recommended method of build version catalogs
...
This fixes broken AGP Upgrade Assistant in Android Studio as well as detects
the version catalog files in Android view.
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-05-30 12:07:51 +05:30
Aayush Gupta
18c85a76c7
gradle: Bump to latest AGP and Gradle version
...
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-05-30 11:44:42 +05:30
Torsten Grote
d9642aec9d
Fix InstallRestriction
...
We had a logic bug where isAllowed actually meant isDisallowed
2024-05-28 14:33:28 -03:00
Chirayu Desai
0a81c42fd1
fixup! restore: Skip installing APKs if not allowed by policy
...
Change-Id: Iaa1590df84e3d1785baf0f938da0a2b2fe43ccd0
2024-05-23 16:06:44 +05:30
Michael Bestas
ecf3b99ac2
misc: Add SPDX copyright headers
2024-05-23 00:44:51 +05:30
Michael Bestas
1baf4b871e
app: Add SPDX copyright headers 5/5
2024-05-23 00:44:51 +05:30
Michael Bestas
bfd51350b2
app: Add SPDX copyright headers 4/5
2024-05-23 00:44:51 +05:30
Michael Bestas
a46e93261c
app: Add SPDX copyright headers 3/5
2024-05-23 00:44:51 +05:30
Michael Bestas
7f7861aba4
app: Add SPDX copyright headers 2/5
2024-05-23 00:44:51 +05:30
Michael Bestas
c1c2385bd5
app: Add SPDX copyright headers 1/5
2024-05-23 00:44:51 +05:30
Michael Bestas
297f335fa9
Add missing newlines at the end of the files
2024-05-23 00:44:51 +05:30
Hosted Weblate
2bbf46bc4a
Import translations from Weblate
...
Co-authored-by: Ettore Atalan <atalanttore@googlemail.com>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: gallegonovato <fran-carro@hotmail.es>
Co-authored-by: lucasmz-dev <git@lucasmz.dev>
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/de/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/es/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/pt/
Translation: CalyxOS/Seedvault
2024-05-23 00:44:39 +05:30
Torsten Grote
54f9e08c71
Fix scheduling for removable drive users
2024-05-23 00:42:47 +05:30
Hosted Weblate
54d9cfcbe7
Import translations from Weblate
...
Co-authored-by: Fjuro <fjuro@alius.cz>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: Igor Sorocean <sorocean.igor@gmail.com>
Co-authored-by: Oğuz Ersen <oguz@ersen.moe>
Co-authored-by: lucasmz <git@lucasmz.dev>
Co-authored-by: lucasmz-dev <git@lucasmz.dev>
Co-authored-by: rehork <cooky@e.email>
Co-authored-by: 大王叫我来巡山 <hamburger2048@users.noreply.hosted.weblate.org>
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/cs/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/pl/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/pt_BR/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/ro/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/tr/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/zh_Hans/
Translation: CalyxOS/Seedvault
2024-05-18 22:48:59 +05:30
Hosted Weblate
684ce8201b
Import translations from Weblate
...
Co-authored-by: Fjuro <fjuro@alius.cz>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: Igor Sorocean <sorocean.igor@gmail.com>
Co-authored-by: Kristian Nordin <kristian.po@proton.me>
Co-authored-by: Oğuz Ersen <oguz@ersen.moe>
Co-authored-by: gallegonovato <fran-carro@hotmail.es>
Co-authored-by: ikya91 <weblate.haq9g@simplelogin.com>
Co-authored-by: lucasmz <git@lucasmz.dev>
Co-authored-by: lucasmz-dev <git@lucasmz.dev>
Co-authored-by: rehork <cooky@e.email>
Co-authored-by: 大王叫我来巡山 <hamburger2048@users.noreply.hosted.weblate.org>
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/cs/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/es/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/fr/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/pl/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/pt_BR/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/ro/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/sv/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/tr/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/zh_Hans/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault_contactsbackup/sv/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault_storage/sv/
Translation: CalyxOS/Seedvault
Translation: CalyxOS/Seedvault contacts backup
Translation: CalyxOS/Seedvault storage backup
2024-05-14 22:21:35 +05:30
Chirayu Desai
422e3f547d
restore: Skip installing APKs if not allowed by policy
...
* We should not bypass the OS-wide APK install restriction.
* Simply treat that as just not having the APK in the first place,
since we do support that as an option.
* This still lets users install apps via the store it was downloaded
from, if said store is installed and allowed to install apps.
* Introduce InstallRestriction to make testing easier.
Co-Authored-By: Torsten Grote <t@grobox.de>
Change-Id: Ic0a56961c9078d4dd542db5d9fc75034abb27bea
2024-05-14 20:34:33 +05:30
Torsten Grote
bb562a4cb2
Catch out 507 HTTP error when using WebDAV
...
Nextcloud has a bug that lets us write chunked transfers over quota:
https://github.com/nextcloud/server/issues/7993
However, when we upload small files, we can get the proper 507 response and thus detect out of space situations and warn the user about them.
2024-05-14 20:31:15 +05:30
Torsten Grote
066b147315
Catch out of space exception during FullBackup
2024-05-14 20:31:15 +05:30
Torsten Grote
860733d238
Don't retry backup on removable storage
2024-05-14 20:31:15 +05:30
Torsten Grote
49262682d1
Don't do backup, if space is already low, warn instead
2024-05-14 20:31:15 +05:30
Torsten Grote
36910fc777
Catch out of space errors and show error notification
2024-05-14 20:31:15 +05:30
Torsten Grote
5cae1b202d
Show app restore sets sorted by latest first
2024-05-14 20:31:15 +05:30
Torsten Grote
7ec80d4ebb
Store total backup size and show it when restoring
...
This is done by storing also the APK sizes in addition to the app data size we already store.
2024-05-14 20:31:15 +05:30
Torsten Grote
1d8c438723
Implement a storage plugin method to get free space
2024-05-14 20:31:15 +05:30
Torsten Grote
81cbb6e4dc
Get free space for storage authority if not available by other means
2024-05-14 20:31:15 +05:30
Torsten Grote
c04ddfa9a0
Add helper text for WebDAV URL field
2024-05-08 19:10:46 +05:30
Torsten Grote
d0cf168198
Merge pull request #647 from grote/webdav
...
Implement a native WebDAV plugin
2024-05-06 13:41:45 -03:00
Torsten Grote
1931024a10
Introduce constant for files snapshot file extension
2024-05-03 16:09:41 -03:00
Torsten Grote
2f6edf6b4b
Rename StoragePluginEnum to StoragePluginType
2024-05-03 15:59:28 -03:00
Torsten Grote
4651ad5eb3
Replace field naming _foo with mFoo
2024-05-03 15:57:01 -03:00
Torsten Grote
01dbcf5f2f
Move StorageProperties class into its own file
2024-05-03 15:54:04 -03:00
Torsten Grote
b041c208ac
Always update next scheduling time in UI
...
Also avoid hard-coded strings and log when no backups are scheduled.
2024-04-29 12:00:39 -03:00
Torsten Grote
0b4bd09e7d
Don't assume SAF-based storage is available
...
it may be WebDAV now
2024-04-25 14:13:32 -03:00
Torsten Grote
0e51c00bca
Properly migrate existing users to new plugin setup
2024-04-25 09:51:46 -03:00
Torsten Grote
a95ba41196
Reset WebDAV config state when the UI is left
2024-04-25 09:51:46 -03:00
Torsten Grote
f4366d930f
Adapt integration test to new plugin structure
2024-04-25 09:51:46 -03:00
Torsten Grote
a4cccabc5e
Don't allow changing backup location while backup is running
2024-04-25 09:51:45 -03:00
Torsten Grote
0e4c37e796
Properly track if a backup is running
...
this is important, so we don't allow more than one backup running at the same time and not swapping out the storage while one is running.
Previously, we had some bare bones tracking, but nothing precise.
2024-04-25 09:51:45 -03:00
Torsten Grote
b1c87a8a9e
Add the UI for the WebDAV plugin
...
including ViewModel and StoragePluginManager logic
2024-04-25 09:51:45 -03:00
Torsten Grote
7e612cb8e0
Introduce StoragePluginManager to handle storage plugins
...
and allow changing them dynamically. So far plugins were injected into the dependency graph and couldn't be changed at runtime, only their config could. Now we have the infrastructure in place to really allow for more than one plugin.
2024-04-25 09:51:45 -03:00
Torsten Grote
2489190824
Rename Storage to SafStorage
...
in preparation for generalization
2024-04-25 09:51:45 -03:00
Torsten Grote
6788d0d25a
Prepare backup destination UI refactoring
...
Mostly renaming for clarity.
2024-04-25 09:51:44 -03:00
Torsten Grote
ec8190755e
Add a method for testing if storage works
...
This is especially useful for WebDAV storage where the user can supply whatever URL and before proceeding, we need to know whether that URL and the provided credentials are actually working.
2024-04-25 09:51:44 -03:00
Torsten Grote
4f2ead66a5
Ensure root folder exists when using storage
...
We use the same root folder for app and files backup. App backup usually creates the root folder, but if only storage backup is used, it will be missing and needs to be created.
2024-04-25 09:51:44 -03:00
Torsten Grote
e6e65d0dd1
WebDAV files backup plugin
2024-04-25 09:51:44 -03:00
Torsten Grote
870d1617d2
Initial implementation of WebDavStoragePlugin
2024-04-25 09:51:43 -03:00
Hosted Weblate
a25ecd1886
Import translations from Weblate
...
Co-authored-by: Anonymous <noreply@weblate.org>
Co-authored-by: Fjuro <fjuro@alius.cz>
Co-authored-by: Fjuro <ifjuro@proton.me>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: Igor Sorocean <sorocean.igor@gmail.com>
Co-authored-by: Kristian Nordin <kristian.po@proton.me>
Co-authored-by: Michael Bestas <mkbestas@gmail.com>
Co-authored-by: Oğuz Ersen <oguz@ersen.moe>
Co-authored-by: Suguru Hirahara <shirahara@users.noreply.hosted.weblate.org>
Co-authored-by: Yaron Shahrabani <sh.yaron@gmail.com>
Co-authored-by: Yuya <yuyaj@tutanota.com>
Co-authored-by: ZehRique <zehrique.dev@gmail.com>
Co-authored-by: gallegonovato <fran-carro@hotmail.es>
Co-authored-by: lucasmz <git@lucasmz.dev>
Co-authored-by: lucasmz <github@lucasmz.dev>
Co-authored-by: lucasmz <lucasmz@users.noreply.hosted.weblate.org>
Co-authored-by: nautilusx <translate@disroot.org>
Co-authored-by: rehork <cooky@e.email>
Co-authored-by: 大王叫我来巡山 <hamburger2048@users.noreply.hosted.weblate.org>
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/cs/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/de/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/el/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/es/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/fi/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/he/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/it/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/ja/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/pl/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/pt/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/pt_BR/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/ro/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/sv/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/tr/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/zh_Hans/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault_contactsbackup/pt/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault_contactsbackup/ro/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault_storage/pt_BR/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault_storage/ro/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault_storage/sv/
Translation: CalyxOS/Seedvault
Translation: CalyxOS/Seedvault contacts backup
Translation: CalyxOS/Seedvault storage backup
2024-04-24 07:31:58 +02:00
Torsten Grote
11fbd450da
Fix nullability for UserManager in AOSP build ( #646 )
2024-04-17 00:12:29 +05:30
Torsten Grote
c8d21fcf34
Auto-disable apps that cancel the entire backup
...
This can happen when the app process gets killed while its BackupAgent is running. There are several qcom apps in the wild that have this issue. These are DoSing our backups and are non-free, so we are defending ourselves against them.
2024-04-16 18:30:20 +05:30
Torsten Grote
499126c459
Log pre-flight errors in BackupMonitor
2024-04-16 18:30:20 +05:30
Torsten Grote
87db20e45f
Include user profile name in backup name
...
so it is easier to identify the right backup if more users backup to the same storage medium.
Change-Id: I56fa93899da3764e20b6aee40adfd52722a05a9f
2024-04-16 18:21:27 +05:30
Torsten Grote
6caa01f8c5
Merge pull request #628 from grote/583-scheduling
...
Move to our own scheduling
2024-03-26 12:23:49 -03:00
Torsten Grote
baef15b2bc
Do live-counting of backed up apps for success notification
...
Previously, we asked the MetadataManager which also includes historic data and may provide misleading totals.
2024-03-19 14:31:36 -03:00
Torsten Grote
db1fc90589
Merge pull request #609 from seedvault-app/feature/rclone
...
Add support for RoundSync as a storage provider
2024-03-18 10:53:25 -03:00
Torsten Grote
f7730d3034
Report total number of user apps when showing final notification
...
Before, we showed the number of apps we requested the backup for which in case of non-d2d may be much lower than the number of installed apps.
In the future we may decide to also include certain system apps in that count.
2024-03-13 09:55:46 -03:00
Aayush Gupta
6e4bf90e7c
BackupScreen: Don't hardcode model name for internal storage
...
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2024-03-12 19:09:21 +05:30
Torsten Grote
0b021e3b48
Try to close system dialogs of emulator
2024-03-08 09:52:23 -03:00
Torsten Grote
8489753d58
Address review feedback
2024-03-08 09:52:23 -03:00
Torsten Grote
ee581ee652
Initialize backup, when enabling it
...
For ApkBackup, we need to be initialized. If the system starts with app backup off, we would not initialize which would lead to issues when backing up the APKs.
2024-03-08 09:52:23 -03:00
Torsten Grote
2da989971b
Request @pm@ backup after initialization
...
to avoid a 2nd restore set being used.
This also changes the initialization behavior to only create the restore set folder and upload the metadata only when we actually need to. This way, double inits are not creating new restore sets on the backup destination.
2024-03-08 09:52:23 -03:00
Torsten Grote
19bfc41d95
Allow backups in metered network, if user wants that
2024-03-08 09:52:07 -03:00
Torsten Grote
4eaa806636
Expose scheduling options in the UI
2024-03-08 09:52:07 -03:00
Torsten Grote
f593b66e00
try more than once to upload metadata after APK backups
...
Failure to upload metadata after backup up APKs can be critical and flaky I/O can make it fail, so we try again.
2024-03-08 09:52:06 -03:00
Torsten Grote
e7e489e091
Only reschedule next app backup when not on USB storage
...
Currently, after a manual run, we need to schedule the background backups again, because the scheduling gets lost. However, we need to be careful not to do that when the backup destination is on removable storage. Then we don't want to run.
2024-03-08 09:52:06 -03:00
Torsten Grote
8a870d8942
Use WorkInfo for determining if a backup is already running
...
Backup and restore is not possible when a backup is running. We used to check notifications for this, but now can use WorkManager's WorkInfo which should be more reliable.
Also, we used to prevent the "Backup now" action when app backup was disabled. But the user may want to do a storage backup. This is now possible.
2024-03-08 09:52:06 -03:00
Torsten Grote
0c1898c198
Properly schedule/cancel backup workers when backup destination changes
...
When the user changes to USB storage, we need to cancel current schedulings, because the storage is not always available (maybe can use a trigger URI?). And if moving to a non-USB storage, we need to schedule backups again.
Unfortunately, there are two places in the code where we handle storage location changes. Ideally, those get unified at some point.
2024-03-08 09:52:06 -03:00
Torsten Grote
e615402458
During restore, show apps without APK as failed
...
Previously, we backed up APKs of apps we could not back up (even if APK backup was disabled) so the user had a chance to get at least the apps back when restoring. Now, it is enough to record metadata about the app and the user will be able to manually install the app. The install apps step won't be skipped anymore.
2024-03-08 09:52:06 -03:00
Torsten Grote
6e7bc89e2f
Respect when worker was stopped
...
and log worker ID as well as object, because we've seen two scheduled workers running at the same time, requesting a backup at the same time. This should not happen.
2024-03-08 09:52:06 -03:00
Torsten Grote
0d7156789e
Guard against BadParcelableException when getting app list
...
hopefully something rare, but it just happened to me while testing.
It seems it happens when there are many apps installed (>500) and the app list is open while a backup happens. Then, we keep reloading the list and hammer the package manager hard which it seems can't handle it. It does recover on its own though.
2024-03-08 09:52:05 -03:00
Torsten Grote
04fc90e9f7
Migrate to own backup scheduling
2024-03-08 09:52:05 -03:00
Torsten Grote
911a8dabf4
Expose time of next backup in UI
...
to help debugging scheduling issues
2024-03-08 09:52:05 -03:00
Torsten Grote
8da73ad8d1
Make 'Backup now' action use AppBackupWorker
2024-03-08 09:52:05 -03:00
Torsten Grote
49066be31b
Improve backup notification
2024-03-08 09:52:05 -03:00
Torsten Grote
fcd4e518a5
Move APK backup from BackupCoordinator to new ApkBackupManager
...
This is a preparation for doing APK backup ourselves in a worker and not hacked into the backup transport. The latter was prone to timeouts by the AOSP backup API. With a worker, we have a bit more control and can schedule backups ourselves.
2024-03-08 09:52:04 -03:00
Torsten Grote
0c8fe3ef20
Fix nullability issues that AOSP is complaining about now
2024-03-07 20:40:09 +05:30
Torsten Grote
c33486ee00
Adjust code for new library versions
2024-03-07 20:40:09 +05:30
Chirayu Desai
635a1ef9b4
strings: Call D2D alpha instead of experimental
...
Change-Id: I571989a04a2cfaa5684d2d182185799b48b51e9e
2024-02-23 23:37:00 +05:30
Chirayu Desai
2744ccdc7d
strings: Call Storage Backup beta instead of experimental
...
* Let's make it less scary
Change-Id: I889b04eb68df836aea3c5cc4ca97acd3f4c3af54
2024-02-23 23:37:00 +05:30
Torsten Grote
8c27814407
Merge pull request #613 from grote/backup-binder
...
Use BackupRequester to request backup in chunks
2024-02-22 13:10:23 -03:00
Michael Bestas
a050e73f7d
Update SetupWizard dark theme for U
...
Change-Id: I0a5b1a41cceba2b45b41cfd64e98b8105c8ad6b6
2024-02-22 01:18:45 +05:30
Torsten Grote
a586ee6b14
In instrumentation tests, keep incremental backups
...
If we request backup in several chunks, packages like 'pm@' or 'android' get backed up for each chunk, so due to incremental backups, we need to keep old data when comparing.
2024-02-14 11:23:22 -03:00
Torsten Grote
b47b4ade1e
Stop cleaning up notification when service is destroyed.
2024-02-13 16:20:02 -03:00
Torsten Grote
4014666c15
Improve notification progress reporting
...
It is still somewhat buggy when d2d is on, but this is easier to resolve when moving everything to own scheduling.
2024-02-13 16:20:02 -03:00
Torsten Grote
86c603e2d2
Use BackupRequester to request backup in chunks
...
Otherwise users with lots of installed apps with request a lot of packages causing binder transactions to reach their size limit and crash.
2024-02-13 16:20:02 -03:00
Torsten Grote
81fae1a240
Try to recover from corrupt metadata cache
2024-02-13 23:37:41 +05:30
Torsten Grote
6428399bed
Tolerate unexpected exceptions in DocumentsStorage and ApkRestore
2024-02-13 23:36:46 +05:30
Torsten Grote
09b7cabd99
Use own notification ID for success notification
...
and cancel observer notification when backup is finished. This is because when the success channel is disabled by the user, the observer notification could stick around and would never get removed.
2024-02-13 23:34:59 +05:30
Torsten Grote
cb9d3c701b
Fix flaky metadata decoding test
2024-02-13 23:34:59 +05:30
Torsten Grote
fcbd62ba3b
Remove warning from d2d expert setting as we now disable system scheduling for d2d
2024-02-13 23:34:59 +05:30
Torsten Grote
c832cd9886
Remove logWorkInfo as some part of it isn't in AOSP version of workmanger
...
It was meant for debugging only anyway
2024-02-13 23:34:59 +05:30
Torsten Grote
a380445693
Show success notification in a separate notification channel
...
so the user can disable it. This will be more of an issue now that it comes also for scheduled background backups.
2024-02-13 23:34:59 +05:30
Torsten Grote
de51ad2cc9
Use our own scheduling when doing d2d backups (experimental)
2024-02-13 23:34:59 +05:30
Hosted Weblate
d1f0fef718
Import translations from Weblate
...
Co-authored-by: 0que <0que@users.noreply.hosted.weblate.org>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: Michael Bestas <mkbestas@gmail.com>
Co-authored-by: Morris Son <morrisson42@gmail.com>
Co-authored-by: Mother is a Gambler <dahlan@disroot.org>
Co-authored-by: Pander <pander@users.sourceforge.net>
Co-authored-by: nautilusx <translate@disroot.org>
Co-authored-by: r5jyhte <ioulykttr@proton.me>
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/de/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/el/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/fr/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/id/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/nl/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/pl/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/ru/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault_storage/ru/
Translation: CalyxOS/Seedvault
Translation: CalyxOS/Seedvault storage backup
2024-02-11 02:05:51 +05:30
Steve Soltys
64d0c87013
Add support for RoundSync as a storage provider
2024-01-27 21:27:59 +00:00
Torsten Grote
9c4f9d8a67
Merge pull request #606 from seedvault-app/chore/version-bump
...
Bump version to 14-4.0 - D2D <3
2024-01-24 17:11:48 -03:00
Chirayu Desai
9097c8ced5
Bump version to 14-4.0 - D2D <3
...
Change-Id: Ida82c6eafa715069d62dc92eb19accf64ed6d51c
2024-01-24 21:28:09 +05:30
Steve Soltys
695c33e466
Merge pull request #603 from seedvault-app/bugfix/excluded-apk-backups
...
Stop backing up excluded app APKs
2024-01-19 09:41:51 -05:00
Steve Soltys
d1e577aec9
Stop backing up excluded app APKs
2024-01-19 03:34:30 +00:00
Torsten Grote
599240c79f
Show size of app backups in Backup Status screen
2024-01-17 13:37:58 -03:00
Torsten Grote
c362da8220
Store size of app backups in metadata
2024-01-16 12:14:28 -03:00
Torsten Grote
0319d733c1
Merge pull request #562 from seedvault-app/feature/d2d-transfer
...
Add experimental support for forcing D2D transfer backups
2024-01-15 11:24:27 -03:00
Steve Soltys
daaf0e0ecc
Add experimental support for forcing D2D transfer backups
2024-01-12 00:12:43 -05:00
Chirayu Desai
57adc57c7f
Bump version and set property for testing
...
* Bump version
* 33030020 -> 13-3.2
* 33030021 -> This, d2d test #478
* 33030022 -> Next, to go back to normal build after testing #489
* Set the testing property to true so that the system
sends us the right app list
14597: Optionally have System-scheduled backups act as migrations | https://review.calyxos.org/c/CalyxOS/platform_frameworks_base/+/14597
Change-Id: I278091b6659db095716e01b6c3894ce345219283
2024-01-02 22:02:53 -05:00
Aayush Gupta
57be15abcf
colors: Switch to public APIs for colors
...
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2023-11-30 21:39:20 +05:30
t-m-w
c2f737458c
Initial support for backup of D2D-only apps
...
Allow backup of apps that would otherwise only support device-to-device
migration. This is an initial-support patch to help determine the
viability of this approach.
Known issues / TODO:
* System-scheduled backups will not handle D2D-only apps, unless
accompanied by a framework change forcing OperationType.MIGRATION.
Backups triggered by the connection of a USB device or by Seedvault's
StorageBackupService (files) scheduling are not affected, so they
*will* back up D2D-only apps as expected; otherwise, the user may
need to perform a backup manually via Backup Now.
* Apps with `allowBackup="false"` will appear in Backup Status under
"Installed Apps" rather than "Apps that do not allow data backup",
and their status will always be blank until they have been backed
up. If they are not eligible for migration, it will never change.
Other notes:
* The unit test for excluding the Storage Plugin provider from backups
was discussed, deemed unnecessary, and removed.
Co-authored-by: Oliver Scott <olivercscott@gmail.com>
Change-Id: I5a23d68be66f7d8ed755f2bccb9570ab7be49356
2023-11-29 23:55:40 -05:00
Torsten Grote
5d19160602
Pretend to be a device to device data transport
...
Change-Id: Ieab13cb15b64e09798ec0c1081d3b3cd975e0811
2023-11-29 23:55:40 -05:00
Torsten Grote
640f5b73c6
Fix double start of restore session
...
We emit the install result of APKs at least two times. When there is no APKs to install, because APK backup was disabled, we would start the restore of app data two times.
This fix waits until the emitted install result is considered finished, so we only start data restore once.
2023-11-28 18:54:32 +05:30
Tommy Webb
18013c0379
Support installing via F-Droid Basic
...
If an app being restored was originally installed with F-Droid Basic,
try to install it using F-Droid Basic again.
Change-Id: Ib067389ba20d74596892e24efd561ab2918d62cb
2023-11-27 19:24:36 +05:30
Torsten Grote
392809274c
Merge pull request #563 from seedvault-app/bugfix/binder-exception-too-many-packages
...
Fix binder exception when restoring a large number of applications
2023-11-27 08:43:08 -03:00
Steve Soltys
b498dab9b1
Apply latest code review suggestions
2023-11-26 14:51:49 -05:00
Oliver Scott
97d2d18a73
fixup! Allow secondary user backup to USB
...
Issue: calyxos#1058
Change-Id: I4aaadef5954e9c091f7048bffd8e0ed700fdd2e6
2023-11-01 17:19:17 -04:00
Steve Soltys
b1a2c6d4cf
Apply code review suggestions
2023-11-01 00:10:00 -04:00
Steve Soltys
6c7afd5f55
Fix binder exception when restoring a large number of applications
2023-10-31 21:38:36 -04:00
t-m-w
a091142a3f
Allow restoring data for a greater number of apps
...
Restore app data in smaller batches when performing a full restoration
from a backup set, to prevent a Binder exception that causes the
process to fail entirely.
Android may encounter this exception when trying to call the
transport.startRestore() method if too many packages are involved; in
testing, 300 is an example of too many. Instead of using
IRestoreSession.restoreAll(), use restorePackages() and provide the
package names in batches of 100.
This issue reveals itself when using SeedVault with the D2D patch and
with an OS, such as stock Pixel OS, that includes an abundance of
packages. (Prior to this patch, the call to restoreAll() meant that the
framework would request data restoration for all packages installed,
even if they were not in the metadata.)
In logs, this issue appears as follows:
```
I BackupManagerService: Full restore; asking about 300 apps
W BpBinder: Large outgoing transaction of 528540 bytes, interface descriptor <uncached descriptor>, code 14
E JavaBinder: !!! FAILED BINDER TRANSACTION !!! (parcel size = 528540)
E BackupManagerService: Unable to contact transport for restore: data parcel size 528540 bytes
```
Change-Id: Ibb5bb4572d9e873beccd6056da5fe3ae4dce71c2
2023-10-31 21:38:36 -04:00
Steve Soltys
b917293bbc
Switch to Kotlin build scripts + version catalog
2023-10-19 00:22:51 -04:00
Steve Soltys
8297bb7087
Fix and improve E2E tests
2023-10-17 21:24:38 -04:00
Torsten Grote
cb95444ad4
Bump minSdk to 33 and upgrade unit test dependencies
2023-10-10 15:44:53 -03:00
Torsten Grote
74566b902a
Upgrade kotlin-bip39-jvm to 1.0.6
...
Bip39ComparisionTest was run before and after upgrading org.bitcoinj:bitcoinj-core to latest version to ensure that kotlin-bip39 is still behaving the same.
A small tweak in WordListTest was needed because WorldList constructor was made internal.
2023-10-10 15:44:52 -03:00
Torsten Grote
bc90378edf
Merge pull request #579 from seedvault-app/staging/android14-bp
...
Get app working in Android 14, built via Android.bp
2023-10-10 15:42:29 -03:00
Chirayu Desai
6cb3b30b84
restore: Runtime-registered broadcasts receivers must specify export behavior
...
See: https://developer.android.com/about/versions/14/behavior-changes-14#runtime-receivers-exported
Change-Id: I6f80a060370a0b202c277924ea8cbf565bc29d6e
2023-10-10 12:08:19 -03:00
Chirayu Desai
aa0e82cfca
ApkInstaller: Supress NewApi for
...
* Pre-34, this was marked as @hide and @TestApi
* We were using it as a system app with hidden APIs allowed,
and having added the framework android.jar to gradle
* 91fa0b1298
made it public, so lint now complains. Silence that.
Change-Id: I5a1ec9847a25a0798726af3867d7660db1528a00
2023-10-09 00:16:15 +05:30
Chirayu Desai
978ab6897b
14: Bump to JavaVersion.VERSION_17
...
* AOSP android-14.0.0_r1 bumped Kotlin to 1.8.10
which requires this
Change-Id: I91f51abbf0b303f3db88c5f4f81c570dd85a6510
2023-10-09 00:01:53 +05:30
Chirayu Desai
a6b32ac3d2
14: Update AOSP libs from gradle, from android-14.0.0_r1
...
* Compiled with a plain `m`, and then copied over
from the paths noted in the comments
Change-Id: If5d399d839886c7fe044f5bb7088ed95259e6bf2
2023-10-09 00:01:53 +05:30
Steve Soltys
d678d9a960
Bump emulator image in Gradle task to android-34
2023-10-09 00:01:26 +05:30
Steve Soltys
bf5dc1958c
Switch to GitHub actions for E2E tests
2023-10-09 00:01:26 +05:30
Chirayu Desai
fcdacf22a7
14: Add new permission FOREGROUND_SERVICE_DATA_SYNC
...
* Android.bp build means we get set to targetSdk 34 already
Fixes: Starting FGS with type dataSync targetSDK=34 requires permissions
See: https://developer.android.com/about/versions/14/changes/fgs-types-required#data-sync
Change-Id: I69932d778e870535522e08dff131f1bb1d128955
2023-10-08 00:39:29 +05:30
Chirayu Desai
e6f32510d5
Bump version to 14-3.3
...
* Android 14 is here!
Change-Id: Ic4249bb1d2a3ac03011f5b7608534ecd526e99c6
2023-10-08 00:39:29 +05:30
Michael Bestas
a83e36634c
seedvault: Enable monochrome icon
...
Just use foreground icon for now
2023-09-26 02:36:50 +05:30
Michael Bestas
09d6131a1c
seedvault: Update app icon
...
* Regenerate in android studio as a single xml instead of png
* Remove roundIcon, this was only used on sdk 25
* Use device accent for icon background
2023-09-26 02:36:50 +05:30
Hosted Weblate
f30acd8b2d
Import translations from Weblate
...
Co-authored-by: Dan <jonweblin2205@protonmail.com>
Co-authored-by: Eric <hamburger2048@users.noreply.hosted.weblate.org>
Co-authored-by: Fjuro <ifjuro@proton.me>
Co-authored-by: František Oboňa <frantisekobona@gmail.com>
Co-authored-by: Hosted Weblate <hosted@weblate.org>
Co-authored-by: Micovec <jiri.vokrinek@email.cz>
Co-authored-by: Oğuz Ersen <oguz@ersen.moe>
Co-authored-by: Yaron Shahrabani <sh.yaron@gmail.com>
Co-authored-by: gallegonovato <fran-carro@hotmail.es>
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/cs/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/es/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/he/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/sk/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/tr/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/uk/
Translate-URL: https://hosted.weblate.org/projects/calyxos/seedvault/zh_Hans/
Translation: CalyxOS/Seedvault
2023-09-25 23:24:03 +05:30
Steve Soltys
6eaba0b87a
Wait until storage location is initialized for e2e test
2023-09-25 22:52:01 +05:30
Steve Soltys
ced8803761
Switch ANDROID_SDK_HOME to ANDROID_HOME
2023-09-22 04:12:53 +00:00
Steve Soltys
29bd71bcc9
Intercept and assert on application data in e2e test
2023-09-21 06:51:43 +00:00
Steve Soltys
04c5089113
Start recording screen again if we get cut off after 3 minutes
2023-09-14 18:42:22 +00:00
Steve Soltys
59cef31183
Address review comments, add screen recording, use test backup data
2023-09-14 18:11:45 +00:00
Steve Soltys
f1238977d0
Add end-to-end emulator test running on CI
2023-09-14 18:11:45 +00:00
Steve Soltys
a922b69094
Add support for local development with an emulator
2023-09-14 17:33:30 +00:00