layerindex-web/layerindex
Tim Orling b0af957ac7 layerindex: improve updates for actual_branch
Some layers now have one branch with many supported
LAYERSERIES_COMPAT. If this branch name does not match
one of the stable releases, LayerBranches might not
have been created. When actual_branch is set, it is
only set in a LayerBranch object. We previously
could not update (create) a stable branch with actual_branch
except manually in the admin interface.

Add --force-create option to be used in conjunction with
--actual-branch (which already requires --branch) in the
update.py script. This tells the script to ignore the
fact that no layerbranch exists already.

Add --actual-branch to update_layer.py so that we can create
(and more importantly checkout) an actual_branch for the
given stable --branch.

Update utils.py to allow checking out of actual_branch when
a LayerBranch does not yet exist.

While we are at it, ensure that any Branch that is marked
as no update will be skipped even with --force-create. The
main reason that a Branch has updates disabled is because the
bitbake or python syntax has changed enough to cause exceptions.

This script can now be run with:

./layerindex/update.py \
  --layer meta-weird-one \
  --branch kirkstone \
  --actual-branch=nonstandard \
  --force-create

Which will attempt to create a meta-weird-one:kirkstone layerbranch
checked out at the 'nonstandard' branch from that layer's git repo.

This allows layerindex admins to at least populate the database
without tedious creation of layerbranches in the admin interface.

Helps make the "branch mapping" actually work and be useful:
[YOCTO #8008]

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2024-01-03 13:33:37 -08:00
..
migrations models.py: add updates_enabled to LayerBranch 2023-10-19 10:32:58 -07:00
static bootstrap: fix typo in minified file name 2023-10-19 14:01:47 -07:00
templatetags Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
tools layerindex/tools: add mark_yp_compatible_layers.py 2023-11-16 07:09:09 -08:00
__init__.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
admin.py admin.py: Remove has_delete_permission() 2022-12-16 08:59:37 -08:00
auth_forms.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
auth_views.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
bulkchange.py layerindex/*: make all shebangs python3 2022-01-13 20:58:28 -08:00
context_processors.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
forms.py layerindex: Add actual_branch to forms and views 2024-01-03 13:33:37 -08:00
layerconfparse.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
middleware.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
models.py layerindex/models.py: fix Inactive-Upstream check 2023-11-17 12:15:49 -08:00
querysethelper.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
recipedesc.py global: replace deprecated distutils 2022-12-16 08:59:37 -08:00
recipeparse.py recipe{desc,parse}.py: BB_ENV_PASSTHROUGH_ADDITIONS 2022-04-28 08:15:22 -07:00
restperm.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
restviews.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
securityquestions.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
tasks.py Add SPDX license headers to layerindex-web source files 2021-04-21 08:22:51 +12:00
update_layer.py layerindex: improve updates for actual_branch 2024-01-03 13:33:37 -08:00
update.py layerindex: improve updates for actual_branch 2024-01-03 13:33:37 -08:00
urls_branch.py layerindex: add Update Layer UI feature 2024-01-03 13:33:37 -08:00
urls.py layerindex: add Update Layer UI feature 2024-01-03 13:33:37 -08:00
utils.py layerindex: improve updates for actual_branch 2024-01-03 13:33:37 -08:00
views.py layerindex: add Update Layer UI feature 2024-01-03 13:33:37 -08:00