git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH v2 0/3] Make check-whitespace failures more helpful

From
CGChris. Webster via GitGitGadget <gitgitgadget@gmail.com>
Date
Dec 20, 2022, 00:35 UTC
Message-ID
<pull.1444.v2.git.1671496548.gitgitgadget@gmail.com>
In-Reply-To
<pull.1444.git.1671179520.gitgitgadget@gmail.com>

Add the errors to the job summary along with suggested commands to fix the problem. The commits and filenames are links.

This is for issue #1395. Sample job output [https://github.com/webstech/check-whitespace/actions/runs/3707382446]:

❌ A whitespace issue was found in one or more of the commits.
Run these commands to correct the problem:
1. git rebase --whitespace=fix aaa04a9
2. git push --force
Errors:
1. --- 5cd37f6 Remove annotations
   trailing.txt:4: trailing whitespace.
   +
   trailing.txt:2: new blank line at EOF.
Chris. Webster (3):
  ci (check-whitespace): suggest fixes for errors
  ci (check-whitespace): add links to job output
  ci (check-whitespace): move to actions/checkout@v3
 .github/workflows/check-whitespace.yml | 57 +++++++++++++++++++++-----
 1 file changed, 46 insertions(+), 11 deletions(-)
base-commit: 57e2c6ebbe7108b35ba30184dcbcb6c34c929ad8
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-1444%2Fwebstech%2Fwhitespace-v2
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-1444/webstech/whitespace-v2
Pull-Request: https://github.com/gitgitgadget/git/pull/1444
Range-diff vs v1:
 1:  67f60e4e5cb ! 1:  a2b5f3e87d6 Make `check-whitespace` failures more helpful
     @@ Metadata
      Author: Chris. Webster <chris@webstech.net>
      
       ## Commit message ##
     -    Make `check-whitespace` failures more helpful
     +    ci (check-whitespace): suggest fixes for errors
      
     -    Add the errors to the job summary along with suggested
     -    commands to fix the problem.
     +    Make the errors more visible by adding them to the job summary and
     +    display the git commands that will usually fix the problem.
      
          Signed-off-by: Chris. Webster <chris@webstech.net>
      
       ## .github/workflows/check-whitespace.yml ##
      @@ .github/workflows/check-whitespace.yml: jobs:
     -   check-whitespace:
     -     runs-on: ubuntu-latest
     -     steps:
     --    - uses: actions/checkout@v2
     -+    - uses: actions/checkout@v3
     -       with:
     -         fetch-depth: 0
     - 
           - name: git log --check
             id: check_out
             run: |
 2:  cdc2b1aae81 ! 2:  342167ef5bd Improve check-whitespace output
     @@ Metadata
      Author: Chris. Webster <chris@webstech.net>
      
       ## Commit message ##
     -    Improve check-whitespace output
     +    ci (check-whitespace): add links to job output
      
          A message in the step log will refer to the Summary output.
      
     -    The job summary output now has links to the commits and files.
     +    The job summary output is using markdown to improve readability.  The
     +    git commands and commits with errors are now in ordered lists.
     +    Commits and files in error are links to the user's repository.
      
          Signed-off-by: Chris. Webster <chris@webstech.net>
      
 -:  ----------- > 3:  aa8cd940940 ci (check-whitespace): move to actions/checkout@v3
-- 
gitgitgadget
Previous: Chris WebsterNext: Chris. Webster via GitGitGadget
Message 10 of 18 in “Make check-whitespace failures more helpful”
  1. 0/2 Make check-whitespace failures more helpfulChris. Webster via GitGitGadget, Dec 16, 2022
  2. 2/2 Improve check-whitespace outputChris. Webster via GitGitGadget, Dec 16, 2022
  3. Junio C HamanoDec 16, 2022
  4. Chris WebsterDec 20, 2022
  5. 1/2 Make `check-whitespace` failures more helpfulChris. Webster via GitGitGadget, Dec 16, 2022
  6. Junio C HamanoDec 16, 2022
  7. Chris WebsterDec 20, 2022
  8. Junio C HamanoDec 20, 2022
  9. Chris WebsterDec 20, 2022
  10. 0/3 Make check-whitespace failures more helpfulChris. Webster via GitGitGadget, Dec 20, 2022
  11. 1/3 ci (check-whitespace): suggest fixes for errorsChris. Webster via GitGitGadget, Dec 20, 2022
  12. Đoàn Trần Công DanhDec 20, 2022
  13. Chris WebsterDec 20, 2022
  14. Đoàn Trần Công DanhDec 21, 2022
  15. Chris WebsterDec 21, 2022
  16. Đoàn Trần Công DanhDec 21, 2022
  17. 2/3 ci (check-whitespace): add links to job outputChris. Webster via GitGitGadget, Dec 20, 2022
  18. 3/3 ci (check-whitespace): move to actions/checkout@v3Chris. Webster via GitGitGadget, Dec 20, 2022

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.