Git status is displayed after copying files

When I copy files from my Linux machine to an external hard drive (FAT format), 'git status' indicates that the files have changed. I assume this is due to differences in the file system.

I formatted the external hard drive using FAT to share it with my Mac, Windows, and Linux.

How can I solve this problem?

Thank.

Sam

+3
source share
4 answers

This may be caused by inconsistent permission bits. From git -config manpage :

core.fileMode

false, ; , FAT. git -update- (1).

+2

core.autocrlf false.
eol ( ) OS/support "".

+2

, (, cp ), , / .

EOL, (, VonC), .

+1

Another solution may be if you are sure that there are no changes between the two folders to check and pull

git checkout -- .
git pull
0
source

Source: https://habr.com/ru/post/1762955/


All Articles