Ensure that the testsuite doesn't generate unchecked temporary files#7483
Ensure that the testsuite doesn't generate unchecked temporary files#7483dlang-bot merged 2 commits intodlang:masterfrom
Conversation
|
Thanks for your pull request, @wilzbach! Bugzilla referencesYour PR doesn't reference any Bugzilla issue. If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog. |
be6211e to
98eacdc
Compare
posix.mak
Outdated
|
|
||
| check-clean-git: | ||
| @git diff-index --quiet HEAD -- || \ | ||
| (echo "ERROR: You created temporary files. Store them in tests_results or remove them."; git status; exit 1) |
There was a problem hiding this comment.
The error message sounds a bit too much like it is accusing the current user, which may not be at fault for the temporary files. How about "ERROR: Found residual temporary files. Temporary files should be stored in test_results or explicitly removed."
Also, the git status tends to overwhelm the error message, making it less obvious. Perhaps use git status -s which displays a less verbose output. In that case you may want to change the error message to "ERROR: Found the following residual temporary files. Temporary files should be stored in test_results or explicitly removed."
Example output:
ERROR: Found the following residual temporary files. Temporary files should be stored in `test_results` or explicitly removed.
?? dub.selections.json
Sorry for being so picky about such things. I can't help it.
There was a problem hiding this comment.
Also, it might be helpful to add a comment with a link to this PR. It helps when maintaining these makefiles to understand why certain things exist.
There was a problem hiding this comment.
Sorry for being so picky about such things. I can't help it.
No that's cool. It really helps to make a better user experience!
| mkdir -p $(INSTALL_DIR)/man | ||
| cp -r docs/man/* $(INSTALL_DIR)/man/ | ||
|
|
||
| check-clean-git: |
There was a problem hiding this comment.
Major targets should have documentation explaining what they do. Otherwise, the user is left to puzzle out the commands executed, which (like all code) isn't always obvious.
WalterBright
left a comment
There was a problem hiding this comment.
document check-clean-git
6863645 to
18c1484
Compare
cfab43e to
ba1de10
Compare
So that #7482 isn't needed anymore in the future.