IssueRaiser

Add diff in output of --check (for CI use cases)

Edit 2025-03-06 by @lydell: This is a very long thread. It starts out with me asking for use cases for this feature. People then provide use cases over and over. It is clear that this is a wanted feature. There is no need to add more comments about that, but do react with 👍 on this post. There is a pull request https://github.com/prettier/prettier/pull/12598 for this feature, but it is (in my opinion) a bit lacking: https://github.com/prettier/prettier/pull/12598#issuecomment-2338648470. I’m not a maintainer anymore, but it seems to me like a good PR for this would be merged. --- More people submit PR for documents in Markdown files or other things via Github web editor. If they make a mistake then the CI fails but there is no chance to inform the user whats wrong. I see some infos should be with the `--debug-check` but currently there is no output with this option. **Environments:** - Prettier Version: 1.18.2 - Running Prettier via: cli - Runtime: node? - Operating System: linux **Steps to reproduce:** ```bash prettier "**/*.{md,css,scss,yaml,yml,ts}" "--check" ``` **Expected behavior:** Show each error and the changes like with `--debug-check` here in #4415 **Actual behavior:** Show nothing about the errors: ```bash > @ prettier /home/circleci/project > prettier "**/*.{md,css,scss,yaml,yml,ts}" "--check" Checking formatting... docs/contributing/environment.md Code style issues found in the above file(s). Forgot to run Prettier? ``` Also there are no more in

Posted by muescha on Nov 8, 2019, 11:03 PM

Tags

Related issues

Raise real-world problems, find people facing the same issue, and discuss solutions.3,500 issues0 comments

github (Sysadmin)

Add diff in output of --check (for CI use cases)

mueschaNov 8, 2019, 11:03 PM

Edit 2025-03-06 by @lydell: This is a very long thread. It starts out with me asking for use cases for this feature. People then provide use cases over and over. It is clear that this is a wanted feature. There is no need to add more comments about that, but do react with 👍 on this post. There is a pull request https://github.com/prettier/prettier/pull/12598 for this feature, but it is (in my opinion) a bit lacking: https://github.com/prettier/prettier/pull/12598#issuecomment-2338648470. I’m not a maintainer anymore, but it seems to me like a good PR for this would be merged. --- More people submit PR for documents in Markdown files or other things via Github web editor. If they make a mistake then the CI fails but there is no chance to inform the user whats wrong. I see some infos should be with the `--debug-check` but currently there is no output with this option. **Environments:** - Prettier Version: 1.18.2 - Running Prettier via: cli - Runtime: node? - Operating System: linux **Steps to reproduce:** ```bash prettier "**/*.{md,css,scss,yaml,yml,ts}" "--check" ``` **Expected behavior:** Show each error and the changes like with `--debug-check` here in #4415 **Actual behavior:** Show nothing about the errors: ```bash > @ prettier /home/circleci/project > prettier "**/*.{md,css,scss,yaml,yml,ts}" "--check" Checking formatting... docs/contributing/environment.md Code style issues found in the above file(s). Forgot to run Prettier? ``` Also there are no more in

Comments (0)

No comments yet. Start the discussion.

Comment on this issue