Support some way to only override parts of upstream config

Hello, I want to disable mirroring of the front camera of my PinePhone, which means setting mirrored=false in the config. But this requires that I copy /usr/share/megapixels/config/$device.ini to ~/.config to make the change. That means I now have to periodically diff the two to make sure that the only difference between upstream's config and mine is this one change. Or come up with some ad-hoc method of dynamically generating the config with this one change at every startup of megapixels, via sed or something.

It would be nice if megapixels let me use the upstream config with only overrides in the custom config. Eg:

# indicates the next file that would be considered in find_config
# should be parsed first


... or whatever else makes sense with inih.

Thanks, Arnavion

Assigned to
9 months ago
7 months ago
No labels applied.

~luigi311 8 months ago

An easy way to handle it would be to read down the list and overwrite previous answers with others set at the bottom megapixels can just dynamically merge in your config with the default one with ours at the bottom which will result in ours overwriting the original values.

~benjamin-schaaf 7 months ago

Register here or Log in to comment, or comment via email.