File tree Expand file tree Collapse file tree 1 file changed +24
-14
lines changed
Expand file tree Collapse file tree 1 file changed +24
-14
lines changed Original file line number Diff line number Diff line change @@ -153,22 +153,32 @@ def process_issue(
153153 new_output = output
154154 else :
155155 new_output = input
156-
157- process_issue_via_oak (
158- input = input ,
159- body = issue [BODY ],
160- output = new_output ,
156+
157+ label_names = [label ['name' ] for label in issue ['labels' ]]
158+
159+ if label in label_names and issue ['number' ] == number :
160+ process_issue_via_oak (
161+ input = input ,
162+ body = issue [BODY ],
163+ output = new_output ,
164+ )
165+
166+ formatted_body += _list_to_markdown (issue [BODY ])
167+
168+ click .echo (
169+ f"""
170+ ::set-output name=PR_BODY::{ formatted_body }
171+ ::set-output name=PR_TITLE::{ issue [TITLE ]}
172+ """
173+ )
174+ break
175+ else :
176+ click .echo (
177+ f"""
178+ { issue [TITLE ]} does not need the bot's attention.
179+ """
161180 )
162181
163- formatted_body += _list_to_markdown (issue [BODY ])
164-
165- click .echo (
166- f"""
167- ::set-output name=PR_BODY::{ formatted_body }
168- ::set-output name=PR_TITLE::{ issue [TITLE ]}
169- """
170- )
171-
172182
173183def _list_to_markdown (list : list ) -> str :
174184 bullet = "- "
You can’t perform that action at this time.
0 commit comments