From 8f2a1fb6ef70021d60b5eb37cd8b4334cf996e1e Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Sat, 17 Dec 2022 10:41:00 -0600 Subject: [PATCH] Danger: don't warn about changelog for docs, CI, etc --- dangerfile.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dangerfile.ts b/dangerfile.ts index 66d25d65a..6ed716fbc 100644 --- a/dangerfile.ts +++ b/dangerfile.ts @@ -1,5 +1,8 @@ import { danger, warn, message } from 'danger'; +// App changes +const app = danger.git.fileMatch('app/soapbox/**'); + // Docs changes const docs = danger.git.fileMatch('docs/**/*.md'); @@ -10,7 +13,7 @@ if (docs.edited) { // Enforce CHANGELOG.md additions const changelog = danger.git.fileMatch('CHANGELOG.md'); -if (!changelog.edited) { +if (app.edited && !changelog.edited) { warn('You have not updated `CHANGELOG.md`. If this change directly impacts admins or users, please update the changelog. Otherwise you can ignore this message. See: https://keepachangelog.com'); }