0

I'm working on a Mac and pulling a repo from GitHub.

I've made a series of changes and GitTower or GIT in general is telling me:

410 files changed, 68615 lines added, 70606 lines deleted

This is completely incorrect other than the files changed number.

I edited at most 20 to 30 lines of code in each file, yet for each file edited GIT says I replaced the entire contents of the file.

I'm assuming this is because the line endings are from a different OS? I normally don't have this issue, this is the first time I'm working on a public repo.

I looked around at some other answers which led me to try and discover my current config via:

git config core.autocrlf

This returns nothing when I run it.

So I'm assuming I need to set it? GitHub recommends "input" for Mac users, will this make sure that my files don't show the entire file was changed?

Also, is there a way to fix the commit I mentioned so that it only shows the correct number of lines changed?

secondman
  • 3,233
  • 6
  • 43
  • 66

1 Answers1

2

Surely, you should set the core.autocrlf. Git-documentation

And to fix the problem, you may need to revert your commit first. Revert to previous Git commit Then, configure it and make a commit again.

Community
  • 1
  • 1
hjason
  • 36
  • 4