AppImage - Include auto-updating logic in to appimage directly?

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
Post Reply
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

AppImage - Include auto-updating logic in to appimage directly?

Post by Kunda1 »

Name: Consider making the AppImage self-updatable from the menu
Ticket: https://github.com/FreeCAD/FreeCAD-AppImage/issues/27
Repo: https://github.com/antony-jr/AppImageUpdaterBridge
Note: this ticket was opened by @probonopd who developed the whole AppImage idea.

How do we do this?

The README says it's testable in this code:

Code: Select all

#include <QCoreApplication>
#include <AppImageUpdaterBridge>
int main(int argc, char **argv)
{
    using AppImageUpdaterBridge::AppImageDeltaRevisioner;

    QCoreApplication app(argc, argv);
    AppImageDeltaRevisioner DeltaRevisioner;
    QObject::connect(&DeltaRevisioner, &AppImageDeltaRevisioner::finished, &app, &QCoreApplication::quit);
    DeltaRevisioner.setShowLog(true); // Display logs?
    DeltaRevisioner.start();
    return app.exec();
}
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: AppImage - Include auto-updating logic in to appimage directly?

Post by looo »

Are there python bindings? I don't think we should make the source dependent on appimage-libraray (also not optional) and also we shouldn't make the package dependent on the appimage-library. I guess it's best to write an extension that adds the updating-process and install this extension during the appimage creation.
triplus
Veteran
Posts: 9471
Joined: Mon Dec 12, 2011 4:45 pm

Re: AppImage - Include auto-updating logic in to appimage directly?

Post by triplus »

I left a note on GitHub.

P.S. In short i feel that people using AppImages can handle a drag and drop operation just fine, for updating. And that already is an elegant and easy solution without introducing any additional maintenance burden and potential issues.
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: AppImage - Include auto-updating logic in to appimage directly?

Post by Kunda1 »

looo wrote: Thu Mar 19, 2020 1:55 pm Are there python bindings? I don't think we should make the source dependent on appimage-libraray (also not optional) and also we shouldn't make the package dependent on the appimage-library. I guess it's best to write an extension that adds the updating-process and install this extension during the appimage creation.
See https://github.com/FreeCAD/FreeCAD-AppI ... -601215162 (the Edit part)
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
triplus
Veteran
Posts: 9471
Joined: Mon Dec 12, 2011 4:45 pm

Re: AppImage - Include auto-updating logic in to appimage directly?

Post by triplus »

I added an additional note on GitHub. Basically what we could do for now is to i guess package the library on Conda and hence include it in the AppImage (next development oriented AppImage). People could play with it after, from FreeCAD Python console. If anything comes out of it, like FreeCAD command providing a frontend, great, if not, just continue to use one of the AppImage updater tools available out there.

P.S. If we don't do that, and just continue to redirect people to using existing external updating tools, that is fine with me too.
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: AppImage - Include auto-updating logic in to appimage directly?

Post by Kunda1 »

triplus wrote: Fri Mar 20, 2020 5:20 pm Basically what we could do for now is to i guess package the library on Conda and hence include it in the AppImage (next development oriented AppImage). People could play with it after, from FreeCAD Python console. If anything comes out of it, like FreeCAD command providing a frontend, great,
:+1:
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: AppImage - Include auto-updating logic in to appimage directly?

Post by looo »

recipe: https://github.com/FreeCAD/FreeCAD_Cond ... /meta.yaml
package: https://anaconda.org/freecad/appimage-u ... idge/files

but I am not sure how to build python bindings. Anyone familiar with shiboken? sry didn't see the link @kunda posted.
User avatar
antonyjr
Posts: 45
Joined: Sat Mar 21, 2020 9:35 pm
Contact:

Re: AppImage - Include auto-updating logic in to appimage directly?

Post by antonyjr »

Thank you for creating the package.

The problem with the build is that you are using the stable version 1.1.6 which does not implement the interface for Qt plugin loader, The implementation is still in alpha and it is present in the plugin branch of the git repo. If possible, please use that branch to build the package to test out the plugin feature.

Also only the qmake project file has the logic to build it has a plugin.
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: AppImage - Include auto-updating logic in to appimage directly?

Post by looo »

antonyjr wrote: Sat Mar 21, 2020 9:40 pm The problem with the build is that you are using the stable version 1.1.6 which does not implement the interface for Qt plugin loader, The implementation is still in alpha and it is present in the plugin branch of the git repo. If possible, please use that branch to build the package to test out the plugin feature.
I see.
antonyjr wrote: Sat Mar 21, 2020 9:40 pm Also only the qmake project file has the logic to build it has a plugin.
Any chance to add the plugin logic to cmake? qmake is a pain with conda-build (at least for me).
User avatar
antonyjr
Posts: 45
Joined: Sat Mar 21, 2020 9:35 pm
Contact:

Re: AppImage - Include auto-updating logic in to appimage directly?

Post by antonyjr »

looo wrote: Sun Mar 22, 2020 6:36 am Any chance to add the plugin logic to cmake? qmake is a pain with conda-build (at least for me).
@looo sure I can. Just wait a bit, I will release all the documentation and also the instruction to build the plugin with cmake ASAP.
.
Post Reply