summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rust/files/triagebot.patch
blob: 715664d081f8f333cfd349f6a9790698e3e3a4e0 (plain)
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
26
27
28
29
30
31
32
Skip tidy triagebot linkcheck if triagebot.toml doesn't exist

Distribution tarballs won't include triagebot.toml, which
causes tidy checks to fail with the following error:

   tidy error: triagebot.toml file not found
   some tidy checks failed

Drop the triagebot.toml check which is mostly to catch broken
path filters *within* `triagebot.toml` and not enforce
the existence of it.

Upstream-Status: Backport [https://github.com/rust-lang/rust/pull/142666/commits]

Signed-off-by: Yash Shinde <Yash.Shinde@windriver.com>
---
diff --git a/src/tools/tidy/src/triagebot.rs b/src/tools/tidy/src/triagebot.rs
--- a/src/tools/tidy/src/triagebot.rs
+++ b/src/tools/tidy/src/triagebot.rs
@@ -6,8 +6,11 @@
 
 pub fn check(path: &Path, bad: &mut bool) {
     let triagebot_path = path.join("triagebot.toml");
+
+    // This check is mostly to catch broken path filters *within* `triagebot.toml`, and not enforce
+    // the existence of `triagebot.toml` itself (which is more obvious), as distribution tarballs
+    // will not include non-essential bits like `triagebot.toml`.
     if !triagebot_path.exists() {
-        tidy_error!(bad, "triagebot.toml file not found");
         return;
     }