Skip to content

Commit

Permalink
Fix PRReview by skipping some extensions
Browse files Browse the repository at this point in the history
  • Loading branch information
CTY-git committed Apr 12, 2024
1 parent 6b5ae2d commit c8ae63c
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions patchwork/steps/ReadPRDiffs/ReadPRDiffs.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,26 @@
from patchwork.logger import logger
from patchwork.step import Step

_IGNORED_EXTENSIONS = [
".png",
".jpg",
".jpeg",
".gif",
".svg",
".pdf",
".docx",
".xlsx",
".pptx",
".zip",
".tar",
".gz",
".lock",
]


def filter_by_extension(file, extensions):
return any(file.endswith(ext) for ext in extensions)


class ReadPRDiffs(Step):
required_keys = {"pr_url"}
Expand Down

0 comments on commit c8ae63c

Please sign in to comment.