openfoodfacts-cordova-app-old-with-blob icon indicating copy to clipboard operation
openfoodfacts-cordova-app-old-with-blob copied to clipboard

Submit the application to FDroid

Open PierrickPuimeanChieze opened this issue 11 years ago • 8 comments

Even if the interface could affray some people, I am a big user of F-Droid. and I was a bit disapointed to not found Open Food Facts init. So here is my request : is it possible to add Open Food Facts to F-Droid ?

PierrickPuimeanChieze avatar Jan 23 '14 12:01 PierrickPuimeanChieze

I tried to build it from source, but I'm not sure what library to add to get barcode scanning working. I tried the core.jar from https://github.com/zxing/zxing/releases/download/zxing-2.3.0/ZXing-2.3.0.zip but it crashes.

dalb8 avatar Feb 26 '14 14:02 dalb8

Ok it doesn't crash at 454dbf41ed32699 but it just shows two dialogs , Alert scan and Alert [object Object]. I did have to put a string for share_name but I didn't know what to put.

dalb8 avatar Feb 26 '14 15:02 dalb8

Hi, It needs the phonegap barcodescanner plugin (which contains a version of the zxing library): https://github.com/wildabeast/BarcodeScanner

openfoodfacts avatar Mar 04 '14 17:03 openfoodfacts

I made a jar from the Android Project of that repo, according to the repo, and added it to libs/ but it doesn't work. I don't understand Cordova/Phonegap much.

dalb8 avatar Mar 05 '14 18:03 dalb8

I created a new cordova app, copied over the resources and run cordova build and it works

I created a pull request with this new layout.

dalb8 avatar Mar 18 '14 09:03 dalb8

I managed to build it with Phonegap eventually. Before running the following I checked out Barcode Scanner plugin at an old commit and backed up www/assets/barcodescanner.js and src/com/phonegap/plugins/barcodescanner/BarcodeScanner.java. I ran plugman --platform android --project Open\ Food\ Facts/ --plugin ../../build/srclib/Wildabeast-BarcodeScanner/ and replaced the files and ran ant release.

It's not sufficient to simply copy the jar from there. Plugman rewrites a few files and adds strings too; without these the scanning activity crashes.

dalb8 avatar Mar 18 '14 13:03 dalb8

Added the metadata to fdroid. The app builds, but I run into the same problems as @dalb8 -- crashes because of the missing barcode scanner. Since I don't have any clue about phonegap/cordova, maybe someone could provide some insight on how to integrate the plugin into the buildscript?

Ref: https://gitlab.com/fdroid/fdroiddata/commit/8ecbb5eb6f28a6c6af0f3157f718e3c1aad613c8

ghost avatar May 31 '15 10:05 ghost

We have the next generation version app in F-Droid. Not the same codebase, tough

teolemon avatar Apr 19 '16 13:04 teolemon