hemker / apkgrabber

APKGrabber is a tool that simplifies the process of finding updates for your installed apps.
GNU General Public License v3.0
426 stars 23 forks source link

Add Github / FDroid Repos source #11

Open Parstion opened 5 years ago

Parstion commented 5 years ago

It's possible to add ?

Atrate commented 5 years ago

For adding GitHub releases, IzzyOnFdroid's repo could be used - he uses Github releases in his repo

TPS commented 5 years ago

@hemker: @IzzySoft's repo shows different versions, but same build number ("29") for every released build. I think that's confusing my F-Droid client. Where does the fix need to be, in the APK or the repo?

IzzySoft commented 5 years ago

As those details get extracted from the APK, there's nothing I can do about that, @TPS – Uh-oh, @hemker: You must increase versionCode with each release!

package: name='de.apkgrabber' versionCode='29' versionName='1.1.4' platformBuildVersionName='8.0.0'
package: name='de.apkgrabber' versionCode='29' versionName='1.1.2' platformBuildVersionName='8.0.0'
package: name='de.apkgrabber' versionCode='29' versionName='1.1.0' platformBuildVersionName='8.0.0

That's what Android (and also F-Droid) identifies a version. Users won't get any update information otherwise!

I just deleted all APKs here except for the latest, so that at least that shows up (and first-timers get the recent version). Please remember increasing versionCode with each new release from now on. Thanks!

hemker commented 5 years ago

@IzzySoft @TPS with version v1.1.7, the version code is incremented. Sorry for the inconvenience, wasn't aware about that

IzzySoft commented 5 years ago

Happens all the time (you're not the first, so no worries :rofl:). Important thing is to detect and fix it – and that we have now. Thanks, @hemker: 1.1.7 should be fetched in about an hour, and with that the issue should be solved.

hemker commented 5 years ago

Perfect, definitely have to setup CD as a short-term goal :smile: @IzzySoft, do you have a REST api to make your repo a possible source for APKGrabber?

IzzySoft commented 5 years ago

First let me confirm: the new package was grabbed and integrated successfully, so the problem reported by @TPS is solved.

As for a "REST API": not exactly. But it's an F-Droid repo, so the same "interfaces" exist – i.e. you could parse the index. Or check whether https://apt.izzysoft.de/fdroid/index/apk/<package_name> returns a 404 (app not there; if it's available, //div.package[1]/h4[1] has version information in its "nodeValue" – but that's only for my repo).

Easiest approach would probably be to grab the index files of all F-Droid Repos you think are interesting (see e.g. my Unofficial (and incomplete) list of F-Droid repositories once per day and parse them on your server to feed some DB with the relevant details. There's e.g. php-fdroid as PHP library to parse the XML index.

IzzySoft commented 5 years ago

No, that's not correct. My fault, copied from the from place and forgot to adjust. Try again, I've fixed it.

jawz101 commented 5 years ago

How would you do this if there is signature mismatches? I would think this is out of scope of this app.

IzzySoft commented 5 years ago

@jawz101 signature mismatches only happen between the F-Droid main repo and other sources – not with my repo and other sources (except for F-Droid main). I don't sign the apps myself, they have the original developers' signatures (as that's where I get the APKs from). F-Droid builds from source and signs with their key, so they have a different signature.