We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8ca6537 commit 96242d8Copy full SHA for 96242d8
dangerfile.js
@@ -14,3 +14,12 @@ if (!hasChangelog && !isTrivial) {
14
warn("Please add your GitHub name to the changelog entry, so we can attribute you.")
15
}
16
17
+
18
+// Warns if there are changes to package.json without changes to yarn.lock.
19
+const packageChanged = includes(danger.git.modified_files, "package.json");
20
+const lockfileChanged = includes(danger.git.modified_files, "yarn.lock");
21
+if (packageChanged && !lockfileChanged) {
22
+ const message = "Changes were made to package.json, but not to yarn.lock";
23
+ const idea = "Perhaps you need to run `yarn install`?";
24
+ warn(`${message} - <i>${idea}</i>`);
25
+}
0 commit comments