fb03e414ee1122f0b9024017baa4bb98c16c2e71

Author
Minh Vu <vuhoangminh97@gmail.com>
Committer
GitHub <noreply@github.com>
Date

Message

ci(deps): detect add-only vendored changes (#13765)

Diff

 1diff --git a/.github/workflows/dependencies/updater.py b/.github/workflows/dependencies/updater.py
 2index b61e5858a3671c8fb3eccbb85e127ba92288d833..2765d9a52169688abd75171a5c097479af0c2c53 100644
 3--- a/.github/workflows/dependencies/updater.py
 4+++ b/.github/workflows/dependencies/updater.py
 5@@ -392,13 +392,15 @@ class Git:
 6         Returns `False` if the repo is dirty.
 7         """
 8         try:
 9-            CommandRunner.run_or_fail(
10-                ["git", "diff", "--exit-code"], stage="CheckRepoClean"
11+            result = CommandRunner.run_or_fail(
12+                ["git", "status", "--porcelain", "--untracked-files=normal"],
13+                stage="CheckRepoClean",
14             )
15-            return True
16         except CommandRunner.Exception:
17             return False
18 
19+        return result.stdout.strip() == b""
20+
21     @staticmethod
22     def add_and_commit(scope: str, version: str) -> bool:
23         """