ChanServ changed the topic of #robotnix to: Robotnix: https://github.com/danielfullmer/robotnix || Channel logs: https://logs.nix.samueldr.com/robotnix
<danielrf[m]> welcome!
<jack[m]1> Hi!
<jack[m]1> I discovered an important lesson about custom_avb keys!
<jack[m]1> You want to make sure you use the same one that you sign the image with.
<samueldr> care to explain how you discovered that? ;)
<jack[m]1> That qualifies as the dumbest thing I've done so far this year.
* jack[m]1 recognizes that the purpose of his life is to serve as a warning for others.
ajs124 has quit [Quit: Bridge terminating on SIGTERM]
ajs124 has joined #robotnix
<matthewcroughan_> danielrf[m]: can you bake an arbitrary path into the image?
<matthewcroughan_> like how you can set `hosts =`, what about an arbitrary path?
<jack[m]1> You'd need to create a module like `modules/hosts.nix` to do it.
<jack[m]1> (There are probably many ways; a module seems to be the simplest)
<matthewcroughan_> Any idea how we could embed this ? https://camera.aeonax.com/
<matthewcroughan_> Are the apks we embed with the `apps` function system apps?
<matthewcroughan_> oh if only we had magisk.enable = true ;D
<danielrf[m]> For your first question: the underlying way to add a file to an arbitrary path is using PRODUCT_COPY_FILES in an android `.mk` file
<danielrf[m]> I have the `system.extraConfig` and `product.extraConfig` which allow you to add arbitrary android makefile stuff into your build
<danielrf[m]> However, the `PRODUCT_COPY_FILES` is a bit lower level, and if the type of thing you are trying to include is supported by the android build system, then you should use the more specific configuration provided by the android build system, instead of PRODUCT_COPY_FILES
<matthewcroughan_> What about these Zip files that you usually find all over the internet, that you flash via TWRP or your recovery?
<matthewcroughan_> Is there a way to "flash" those as part of the robotnix build? And what does "flashing" actually mean? Just overlaying the files on your filesystem?
<danielrf[m]> See also that `modules/etc.nix` for the example using the `LOCAL_MODULE_CLASS := etc`
<danielrf[m]> Instead of using those random zips, the right way to custom builds is to figure out the right way to include them into the android build system
<danielrf[m]> I really haven't used magisk or any of those random things that are sideloaded
<danielrf[m]> and for what I've personally wanted, I've been able to find ways to include them in the android build properly
<matthewcroughan_> huh, okay
<matthewcroughan_> scary :D
<danielrf[m]> At least for vanilla/grapheneos), since it retains retain verified boot, we don't have the ability to make random changes to my /system, /product, or /vendor on a running device
<matthewcroughan_> this app looks pretty insane to build
<danielrf[m]> Yeah, the "Steps to Port MiuiCamera from scratch" look pretty involved
<danielrf[m]> but if those steps could be nixified it would be nice
<danielrf[m]> I've had thoughts in the past about having a nice nixified way to use apktool to decompile / patch / reassemble external apks
<samueldr> flashable zips cannot be applied "offline"
<samueldr> at least, not in a generic manner
<matthewcroughan_> I can't for the life of me figure out how to even install this thing :D
<samueldr> the way it works is it runs either of: an "edify" script, or a static binary, taken from the zip
<samueldr> and this binary can do **anything**
<samueldr> literally anything
<samueldr> if you want to look at an independent implementation
<samueldr> (they are different links)
<samueldr> "edify" is both a scripting language and a "runtime", of sorts
<samueldr> AFAIUI all edify commands here could be used through the FD even without using the actual edify scripting language
<matthewcroughan_> Lol great, so I flashed these zips and nothing happened.
<matthewcroughan_> It's so insane, the instructions.
<matthewcroughan_> 1. Flash this zip, 2. then flash this one, 3. then flash this one.
<matthewcroughan_> >In case you have encountered a bootloop after have flash ANXCamera v190 and ANXFramework v190, flash the add-on Bootloop Fix v190.