[llvm] 09effa7 - [llvm][github] Add good-first-issue comment to issues

Timm Bäder via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 13 05:40:39 PDT 2023


Author: Timm Bäder
Date: 2023-04-13T14:39:59+02:00
New Revision: 09effa706a026c7ebcc01bf14f9f710cb1a8fa87

URL: https://github.com/llvm/llvm-project/commit/09effa706a026c7ebcc01bf14f9f710cb1a8fa87
DIFF: https://github.com/llvm/llvm-project/commit/09effa706a026c7ebcc01bf14f9f710cb1a8fa87.diff

LOG: [llvm][github] Add good-first-issue comment to issues

Differential Revision: https://reviews.llvm.org/D146819

Added: 
    

Modified: 
    llvm/utils/git/github-automation.py

Removed: 
    


################################################################################
diff  --git a/llvm/utils/git/github-automation.py b/llvm/utils/git/github-automation.py
index 66a9534c097cf..b949899742d18 100755
--- a/llvm/utils/git/github-automation.py
+++ b/llvm/utils/git/github-automation.py
@@ -18,6 +18,27 @@
 import time
 from typing import List, Optional
 
+beginner_comment =
+"""
+Hi!
+
+This issue may be a good introductory issue for people new to working on LLVM. If you would like to work on this issue, your first steps are:
+
+  1) Assign the issue to you.
+  2) Fix the issue locally.
+  3) [Run the test suite](https://llvm.org/docs/TestingGuide.html#unit-and-regression-tests) locally.
+    3.1) Remember that the subdirectories under `test/` create fine-grained testing targets, so you can
+         e.g. use `make check-clang-ast` to only run Clang's AST tests.
+  4) Create a `git` commit
+  5) Run [`git clang-format HEAD~1`](https://clang.llvm.org/docs/ClangFormat.html#git-integration) to format your changes.
+  6) Submit the patch to [Phabricator](https://reviews.llvm.org/).
+    6.1) Detailed instructions can be found [here](https://llvm.org/docs/Phabricator.html#requesting-a-review-via-the-web-interface)
+
+For more instructions on how to submit a patch to LLVM, see our [documentation](https://llvm.org/docs/Contributing.html).
+
+If you have any further questions about this issue, don't hesitate to ask via a comment on this Github issue.
+"""
+
 class IssueSubscriber:
 
     @property
@@ -34,7 +55,12 @@ def run(self) -> bool:
         for team in self.org.get_teams():
             if self.team_name != team.name.lower():
                 continue
-            comment = '@llvm/{}'.format(team.slug)
+
+            comment = ''
+            if team.slug == 'issue-subscribers-good-first-issue':
+                comment = '{}\n'.format(beginner_comment)
+
+            comment += '@llvm/{}'.format(team.slug)
             self.issue.create_comment(comment)
             return True
         return False


        


More information about the llvm-commits mailing list