Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Benign attempt to resolve strange LF --> CRLF issue on Joe's machine #630

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

joeflack4
Copy link
Contributor

@joeflack4 joeflack4 commented Aug 7, 2024

Overview

Add .gitattributes to .gitignore
This allows individual contributors to add a .gitattributes for their needs, but opts for individualized .gitattributes per contributor.
Use case: One contributor is having an issue where, despite global git configuration, a lot of the line endings for files are getting converted to CRLF (Windows) rather than LF (Unix). The .gitattributes solution attempts to solve this, but since others aren't having this issue, it may be better to not bloat the repo by adding a file that it doesn't generally need.

Pre-merge checklist

Documentation

Was the documentation added/updated under docs/?

  • Yes
  • No, updates to the docs were not necessary after careful consideration

QC

Was the full pipeline run before submitting this PR using sh run.sh make build-mondo-ingest on this branch (after
docker pull obolibrary/odkfull:dev), and no errors occurred?

  • Yes
  • No, there are no functional (code-related) changes to the pipeline in the PR, so no re-run is necessary

New Packages

Were any new Python packages added?

Were any other non-Python packages added?

PR Review and Conversations Resolved

Has the PR been sufficiently reviewed by at least 1 team member of the Mondo Technical team and all threads resolved?

  • Yes

This allows individual contributors to add a .gitattributes for their needs, but opts for individualized .gitattributes per contributor.
Use case: One contributor is having an issue where, despite global git configuration, a lot of the line endings for files are getting converted to CRLF (Windows) rather than LF (Unix). The .gitattributes solution attempts to solve this, but since others aren't having this issue, it may be better to not bloat the repo by adding a file that it doesn't generally need.
@joeflack4
Copy link
Contributor Author

Will bring this up at next 1:1 meeting.

@twhetzel
Copy link
Contributor

twhetzel commented Aug 8, 2024

@joeflack4 do you have a follow-up commit somewhere to show the before and after effect of using this to specify the end of line issue you're encountering?

@joeflack4
Copy link
Contributor Author

I expect no before/after effect on the git history. If it actually helps, I should only notice the effect on on my end.

I still don't understand why this is happening all of a sudden and only in some of my repos, why it doesn't listen to my global configs, and also sometimes when I pushed, I did see line end differences, but I haven't seen that for a while. If I commit and I do see differences, I'll revert and abandon this .gitattributes solution.

@matentzn
Copy link
Member

After reflecting on this:

While it is uncommon to do this, this allows @joeflack4 to configure his repo locally in whatever way he wants. It does not affect the other team members. The only reason to not merge this is if we believe that we have to figure out the root cause of the issue, but this is the plaster that stops the bleeding and stopping the bleeding is good enough, I think we should merge this and move on. It is indeed a totally benign change for other team members!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants