[llvm] [CI] Make email check workflow fail when author's email is private in Github UI (PR #148694)

David Spickett via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 15 02:07:03 PDT 2025


================
@@ -20,14 +21,33 @@ jobs:
 
       - name: Extract author email
         id: author
+        env:
+          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
         run: |
-          git log -1
-          echo "EMAIL=$(git show -s --format='%ae' HEAD~0)" >> $GITHUB_OUTPUT
+          # Use Github GraphQL APIs to get the email associated with the PR author.
----------------
DavidSpickett wrote:

Add something like "because this takes into account the GitHub settings for email privacy.".

Unlikely anyone will need to change it later but there is a small chance we have to audit all GitHub API uses at some point so knowing that this one is important is useful.

https://github.com/llvm/llvm-project/pull/148694


More information about the llvm-commits mailing list