mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-04 20:01:55 +00:00
Try to improve Danger rule for PNGs to ignore screenshots (#234)
This commit is contained in:
committed by
GitHub
parent
73b79cadd0
commit
93a77d94c1
@@ -107,7 +107,9 @@ if (hasChangedViews) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Check for pngs on resources
|
// Check for pngs on resources
|
||||||
const hasPngs = editedFiles.filter(file => file.toLowerCase().endsWith(".png")).length > 0
|
const hasPngs = editedFiles.filter(file => {
|
||||||
|
file.toLowerCase().endsWith(".png") && !file.includes("snapshots/images/") // Exclude screenshots
|
||||||
|
}).length > 0
|
||||||
if (hasPngs) {
|
if (hasPngs) {
|
||||||
warn("You seem to have made changes to some images. Please consider using an vector drawable.")
|
warn("You seem to have made changes to some images. Please consider using an vector drawable.")
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user