From ce6112be09ef1f8f0c08a2d6f52afb8fa463b428 Mon Sep 17 00:00:00 2001 From: Stephan Kulow Date: Wed, 23 Mar 2022 09:55:42 +0100 Subject: [PATCH] Add some documentation for pkglistgen staging workflow While writing it, I noticed that 'approve' also needs to change the exit value of the pkglistgen pipeline step - fixed --- docs/pkglistgen.md | 9 ++++++++- osclib/pkglistgen_comments.py | 3 +++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/docs/pkglistgen.md b/docs/pkglistgen.md index 095b5d2b..59736d77 100644 --- a/docs/pkglistgen.md +++ b/docs/pkglistgen.md @@ -12,7 +12,7 @@ The generated release spec files are split into 000release-packages to avoid nee The package list generator reads several files. The most important are group*.yml (tradionally only groups.yml) within 000package-groups. ### supportstatus.txt - TODO +The file lists the packages and their support level. It's only necessary to list packages here that have a different level than the default level specificied in the groups. The format is plain text: - the level is handed over 1:1 to KIWI file. Currently used values are: unsupported, l2 and l3 ### group*.yml The file is a list of package lists and the special hash 'OUTPUT'. OUTPUT contains an entry for every group file that needs to be written out. The group name of it needs to exist as package list as well. OUTPUT also contains flags for the groups. @@ -90,3 +90,10 @@ list2: ## Overlap calculcation TODO +## Handling in staging workflow +If 000package-groups contains a file named summary-staging.txt, the bot will trigger a diff mode on staging projects. +It will create an equal summary-staging.txt in 000product and create a comment with a human readable diff in the staging +project. This comment can be replied to. If the reply starts with 'approve', staging accept will apply the diff to this +txt file. If the reply starts with 'ignore', the bot will continue with the pipeline and do nothing on staging accept. + +This way simple changes to the summary can be accepted without a submit request (of which there can only be one at a time). \ No newline at end of file diff --git a/osclib/pkglistgen_comments.py b/osclib/pkglistgen_comments.py index 0e31fe29..217c5c39 100644 --- a/osclib/pkglistgen_comments.py +++ b/osclib/pkglistgen_comments.py @@ -128,6 +128,9 @@ class PkglistComments(object): if ct.startswith('ignore ') or ct == 'ignore': print(c) return 0 + if ct.startswith('approve ') or ct == 'approve': + print(c) + return 0 return 1