core: pkgrepo: support arbitrarily named pmaports directories
- Nov 03, 2024
-
-
We shouldn't overwrite config.aports if the user specified a custom --aports directory. We only want to do this to update the default if they're using a custom workdir. Make the code here less aggressive, and correctly use the last entry in config.aports as "pmaports" instead of the first. Fixes: #2386 Signed-off-by:
Caleb Connolly <caleb@postmarketos.org>
-
There was an oversight when this API was originally created and it implicitly assumed that the pmaports repository was always named "pmaports". This unfortunately broke some peoples workflows. Introduce a new "pkgrepo_name()" function and adjust the codebase to use it, as well as adjusting pkgrepo internally to special case the "pmaports" repo so that it's always named pmaports no matter what the directory itself is named. This is probably more complexity than we should be dealing with here, we should probably create a new type to encode this behaviour. Fixes: #2412 Signed-off-by:
Caleb Connolly <caleb@postmarketos.org>
-
When pmbootstrap starts up, it loads the config file (or uses the defaults) and then merged some arguments (e.g. --work) into it. However in config.init.frontend() we were creating yet another new Config, but it's too late to merge args in at this point... Rework this slightly to fix that major oversight and remove the totally unnecessary hack of calling pmb.config.load() again. This fixes calling pmbootstrap init with --work Signed-off-by:
Caleb Connolly <caleb@postmarketos.org>
-