- Notifications
You must be signed in to change notification settings - Fork1.2k
chore(ci): Add CRLF detection and fix targets to prevent CRLF contamination#1898
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:main
Are you sure you want to change the base?
Conversation
…nationAdd two new Makefile targets to detect and fix carriage return (CRLF)line endings that can contaminate the codebase from Windows environments:- check-crlf: Scans all text files (excluding hidden dirs and vendor) for CRLF line endings and fails if any are found- fix-crlf: Automatically converts CRLF to LF using the tr commandAdd CRLF check to CI workflow to catch line ending issues early in PRs.The check runs immediately after checkout, before any other validation.Also rename go.yml to validate.yml to better reflect the workflow'spurpose, and fix job name casing (supportedVersions -> supported_versions).Signed-off-by: Kemal Akkoyun <kemal.akkoyun@datadoghq.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Thanks! One nit only
| steps: | ||
| -name:Checkout code | ||
| --- | ||
| name:Validate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Can we keep Go name (also in file)? Otherwise we need to change GH CI required checks and generally change the experience of contributing to client_golang. Is it worth the name change?
Add two new Makefile targets to detect and fix carriage return (CRLF)
line endings that can contaminate the codebase from Windows environments:
for CRLF line endings and fails if any are found
Add CRLF check to CI workflow to catch line ending issues early in PRs.
The check runs immediately after checkout, before any other validation.
Also rename go.yml to validate.yml to better reflect the workflow's
purpose, and fix job name casing (supportedVersions -> supported_versions).
Signed-off-by: Kemal Akkoyunkemal.akkoyun@datadoghq.com