forked from zed-industries/extensions
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdangerfile.ts
More file actions
25 lines (22 loc) · 680 Bytes
/
dangerfile.ts
File metadata and controls
25 lines (22 loc) · 680 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import { danger, warn } from "danger";
const { prHygiene } = require("danger-plugin-pr-hygiene");
prHygiene({
rules: {
// Don't enable this rule just yet, as it can have false positives.
useImperativeMood: "off",
},
});
const wasExtensionsTomlModified = danger.git.modified_files.some((file) =>
file.includes("extensions.toml"),
);
if (!wasExtensionsTomlModified) {
warn(
[
"This PR doesn't include changes to `extensions.toml`.",
"",
"If you are creating a new extension, add a new entry to it.",
"",
"If you are updating an existing extension, update the version number in the corresponding entry.",
].join("\n"),
);
}