Commit Graph

315 Commits

Author SHA1 Message Date
Torsten Grote
c1e4e27797 Auto-try legacy installer when install verification fails
This is useful for users with Google Advanced Protection who can use this to circumvent install restrictions and still use F-Droid. See #3201
2026-06-15 15:14:57 -03:00
Torsten Grote
f4f6041518 Work around Chinese ROMs aborting installation pre-approval
There's a second code path for updates where we can't ask for pre-approval right away, so it needs to be triggered by the user when they see the UI. This code path gets hit for automatic updates or when the user wants to update many apps at once.

There we also measure time to abort and if it is faster than 250ms we continue without pre-approval.
2026-06-15 15:14:56 -03:00
Torsten Grote
2778299cb4 Show self-update notification also when user triggered update
before we were showing it only when the app was in foreground when it started to self-update
2026-06-15 15:14:55 -03:00
Torsten Grote
ff381e7c37 Only show self-update notification when the app was in foreground before update 2026-06-11 13:17:18 -03:00
Torsten Grote
b89f10d8d2 Fix bug with ignore all updates
which would not show a suggested version and prevent installation for previously uninstalled apps
2026-06-04 09:39:07 -03:00
Torsten Grote
8bde3876c5 Show suggested version even if already installed
or a newer version is already installed
2026-06-04 09:39:06 -03:00
Torsten Grote
3e3fc846aa Disable pre-approval for Chinese users
as it is broken in many Chinese ROMs. In the future, we can gradually do extra checks for Chinese users and re-enable it for some of them.

This is just way easier than trying to detect Chinese ROMs which is a research project of its own.
2026-06-04 09:39:05 -03:00
Torsten Grote
9ccc81b96d Add setting to only update repos when app is opened
if enabled, this auto updates repos, when user opens app and if last check was more than 12h ago
2026-06-04 09:39:03 -03:00
Torsten Grote
63ca340f97 Add unit tests for DetailsPresenter 2026-06-04 09:39:02 -03:00
Torsten Grote
ebddb760cf Don't crash when system sends us duplicate installation broadcasts 2026-04-28 08:58:39 -03:00
Torsten Grote
98c7d3cb71 Move search into bottom nav bar 2026-04-09 11:28:39 -03:00
Torsten Grote
6ac59f1cc0 Add search history feature 2026-04-09 11:28:36 -03:00
Torsten Grote
f439614e36 Move SearchManager out of ui package 2026-04-09 11:28:35 -03:00
Torsten Grote
d8bc2dc29e Delay initial loading of updates to not hammer DB during start-up 2026-04-03 13:21:15 -03:00
Torsten Grote
54e69a49fa Use more generic PackageVersion in AppInstallManager 2026-04-03 13:21:13 -03:00
Torsten Grote
f82af73234 Support a single canonical location for preloaded repos
in RepoPreLoader and add tests for the entire class
2026-04-03 13:21:11 -03:00
Torsten Grote
91a880a236 Add tests for search in app lists 2026-03-26 14:38:56 -03:00
Torsten Grote
2d7cf4f455 Use new SearchQueryRewriter and adapt for improved Chinese queries 2026-03-26 14:38:55 -03:00
Torsten Grote
5c64b8ec1a Add tests for SearchManager
An attempt to already test against a real in memory DB failed due to the module separation. So the search will be tested from two sides. This is the UI side and the DB side comes later.
2026-03-26 14:38:54 -03:00
Torsten Grote
d85f9a9963 Add tests for InstalledAppsCache 2026-03-26 14:38:51 -03:00
Torsten Grote
68ae977d9c Add a small test for CacheCleaner 2026-03-26 14:38:51 -03:00
Torsten Grote
53496d1d3a Add tests for SessionInstallManager 2026-03-26 14:38:50 -03:00
Torsten Grote
59d181e651 Add tests for AppInstallManager 2026-03-26 14:38:49 -03:00
Torsten Grote
d3f6b3d692 Add tests for RepoUpdateManager 2026-03-26 14:38:49 -03:00
Torsten Grote
af8058314b Add tests for UpdatesManager and the new UpdateInstaller 2026-03-26 14:38:49 -03:00
Torsten Grote
2d7e94c7a5 Migrate to AGP9
fixes multi-platform JVM builds
2026-03-06 17:39:31 -03:00
Torsten Grote
cdf58c6ffb Auto-format all files with ktfmt 2026-02-26 17:12:13 -03:00
Torsten Grote
9c41763a10 Add install history feature 2026-02-13 11:39:19 -03:00
Torsten Grote
d3164687cd Clean up app gradle modules 2026-01-05 17:24:14 -03:00
proletarius101
f992d2c265 feat: add PMD linting integration to GitLab CI 2025-10-21 12:11:53 +00:00
Torsten Grote
389bd93182 Add tests for RepoUpdateManager 2025-08-15 15:17:52 -03:00
Torsten Grote
31588a02c0 Retry when updating apps failed 2025-07-24 12:36:43 +00:00
Torsten Grote
328f617b8e Remove roboelectric shadow hacks
that cause issues now and seem no longer needed
2025-05-22 14:20:39 -03:00
Torsten Grote
a69915ee89 Add AppUpdateManagerTest 2025-05-22 13:41:52 -03:00
mnbogner
621bd7a5e4 additional changes to reduce concurrency risk 2025-04-03 11:06:58 +00:00
mnbogner
26e1e1f183 added additional error checking and unit test 2025-04-03 11:06:58 +00:00
Torsten Grote
1b7a55b043 Upgrade all the things!
Use version catalog now and upgrade ktlint as well.
2024-10-17 17:41:12 +00:00
Torsten Grote
b1631f5078 [app] add default repos before ROM repos, so they end up with higher priority 2024-04-30 11:55:23 -03:00
Torsten Grote
3d114cd85f Remove dead NFC (Android Beam) code 2024-03-05 14:43:28 +00:00
Torsten Grote
f6970e4245 [app] allow changing preferred repo in app details 2024-02-20 09:42:40 -03:00
Torsten Grote
393c74ab35 [app] adapt to new AppPrefs constructor 2024-02-20 09:42:39 -03:00
Torsten Grote
e1cc9cf4cf [app] Add test for QRCode byte count in lowercase 2023-09-22 08:07:36 +00:00
Hans-Christoph Steiner
48a10cac17 whitespace fixes from spotless applying AOSP code format 2023-07-05 21:40:12 +02:00
Torsten Grote
2048d6f478 Add code style to repo and fix it 2023-06-09 17:24:58 +00:00
Torsten Grote
6fadebe4e2 [app] Show more precise relative last updated dates 2023-02-07 14:09:35 +00:00
Hans-Christoph Steiner
9ab226b3fb re-add sig field for use in swap v1 compatibility checks
With index-v2, "signer" will be the only field used, since "sig" is
deprecated and should be removed.  "sig" needs to be kept only for
generating the index-v1.jar in nearby/swap repos so that it remains
compatible with older clients.  This code base should no longer use
"sig" for anything besides writing it out to index-v1.json.
2023-01-20 15:21:11 +01:00
Hans-Christoph Steiner
e3550171aa rename all cases where "sig" or "signature" should be "signer"
* "signer": standard SHA-256 fingerprint of the APK Signing Certificate
* "sig": fdroid-specific MD5 fingerprint of the APK Signing Certificate
2023-01-20 15:21:11 +01:00
Torsten Grote
76070f09ff [app] Fix weight (priority) of additional repos
Our old DbHelper code would assign all additional repos a weight of 0 which the new database implementation doesn't like. Apps from those repos would simply not appear as if the repo is disabled.

This fix simplifies the weight assignment of initial repos by incrementing the weight for each repo, so the weight assignment works the same way as for manually added repos: later repos get a higher weight.

Incidentally, this also unifies the format of `additional_repos.xml` and `default_repos.xml`.
2023-01-13 15:25:55 +01:00
Torsten Grote
cbb8aa5a50 [app] Fix release channel logic in App#findSuggestedApk()
Stable updates are always allowed, even if we also allow beta updates.
2023-01-12 10:31:32 -03:00
Hans-Christoph Steiner
3fa5e98fc4 convert SwapRepoTest into initial UpdateServiceTest
Finally, there can be a test for running UpdateService, which is essential
and has some really hairy code in it.  At least swap has been removed from
there.  This is barebones still, but it now can be developed to test quite
a bit of what is still needed in UpdateService.
2022-12-01 17:43:14 +01:00