Pushing locally build packages to devices or emulators running pmOS
I've talked a bit about this with some people at Akademy. For an Android developer to push and test his/her new changes, he/she can just press a button and the project automatically gets compiled, send to the device, and started. Especially for new developers, this is a great experience.
Right now on postmarketOS (or well, proper Linux on phones in general) we have no such thing. We can build the packages locally, but to push it to your device or Qemu, you'll have to manually set up a webserver or push it via scp, or even create an entirely new image. I'd like to automate that somehow through pmbootstrap
, and where possible also launch the application automatically.
In my head the process would be something like this:
- an app developer writes a new program
- he writes an APKBUILD to build and package the application (or uses
pmbootstrap newapkbuild
to do so) - he executes something like
pmbootstrap push <package name>
which automatically compiles the package (pmbootstrap build --force --strict <package name>
) and sends it to the device - postmarketOS tries to automatically launch it on the device if a UI is installed
For actually sending the package to a device it's probably easiest to follow the approach we recommend now by quickly launching a webserver where we serve the just compiled package.
On the device side, we might need some small application or daemon which listens to the PC for signals to pull the package and try to launch it.
What do you guys think about this? Is this do-able? It could eventually probably be integrated with IDE's like KDevelop so developers can literally just press a button and see their application launch on their phone or emulator.