[llvm] 3dda104 - [docs] Advise contributors to check for truncated PR titles (#68021)

via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 2 13:14:00 PDT 2023


Author: Alex Bradbury
Date: 2023-10-02T21:13:55+01:00
New Revision: 3dda1040d3fe56dbd8afd2eb823e891954de13f3

URL: https://github.com/llvm/llvm-project/commit/3dda1040d3fe56dbd8afd2eb823e891954de13f3
DIFF: https://github.com/llvm/llvm-project/commit/3dda1040d3fe56dbd8afd2eb823e891954de13f3.diff

LOG: [docs] Advise contributors to check for truncated PR titles (#68021)

GitHub will use the first line of the commit as the title for a
single-commit PR, but truncates it at 72 characters
<https://github.com/orgs/community/discussions/12450>. This truncation
makes the PRs less readable if not manually undone, and even worse, the
truncated form may survive through to commit if "Squash and rebase" is
used in the GitHub web UI. From preparing LLVM Weekly, I've seen this a
number of times and it really does make it more annoying to flick
through commits.

I'm not sure if this is the best place for the guidance, or whether you
get the same behaviour when creating a PR with `gh`, but I'm quite keen
we give a warning of some sort about this behaviour.

Added: 
    

Modified: 
    llvm/docs/GitHub.rst

Removed: 
    


################################################################################
diff  --git a/llvm/docs/GitHub.rst b/llvm/docs/GitHub.rst
index 79f1479716faefa..67fea9520aab6de 100644
--- a/llvm/docs/GitHub.rst
+++ b/llvm/docs/GitHub.rst
@@ -50,6 +50,9 @@ Create a local branch per commit you want to submit and then push that branch
 to your `fork <https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks>`_
 of the llvm-project and
 `create a pull request from the fork <https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request-from-a-fork>`_.
+As GitHub uses the first line of the commit message truncated to 72 characters
+as the pull request title, you may have to edit to reword or to undo this
+truncation.
 
 Creating Pull Requests with GitHub CLI
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^


        


More information about the llvm-commits mailing list